From 593fa3c0c4daf7dda018ea76b380eedb02883ca6 Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Wed, 27 Feb 2019 16:46:16 +0100 Subject: [PATCH] Consolidate code, use dedicated API --- gtk2_ardour/control_slave_ui.cc | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/gtk2_ardour/control_slave_ui.cc b/gtk2_ardour/control_slave_ui.cc index 0c8ad87d28..50a10b03b2 100644 --- a/gtk2_ardour/control_slave_ui.cc +++ b/gtk2_ardour/control_slave_ui.cc @@ -199,10 +199,7 @@ ControlSlaveUI::vca_button_release (GdkEventButton* ev, uint32_t n) items.push_back (CheckMenuElem ((*v)->name())); Gtk::CheckMenuItem* item = dynamic_cast (&items.back()); - boost::shared_ptr gcs = stripable->gain_control(); - boost::shared_ptr gcm = (*v)->gain_control(); - - if (gcs->slaved_to (gcm)) { + if (stripable->slaved_to (*i)) { item->set_active (true); slaved = true; }