From 01c6f558672f4202f953ea4c3401f08f3d9fc306 Mon Sep 17 00:00:00 2001 From: Ben Loftis Date: Tue, 18 Feb 2020 20:14:00 -0600 Subject: [PATCH] Prompt user before removing a VCA in the mixer window. --- gtk2_ardour/vca_master_strip.cc | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/gtk2_ardour/vca_master_strip.cc b/gtk2_ardour/vca_master_strip.cc index 574655427e..f23350e0b6 100644 --- a/gtk2_ardour/vca_master_strip.cc +++ b/gtk2_ardour/vca_master_strip.cc @@ -32,9 +32,11 @@ #include "widgets/tooltips.h" #include "ardour_dialog.h" +#include "ardour_message.h" #include "floating_text_entry.h" #include "gui_thread.h" #include "mixer_ui.h" +#include "public_editor.h" #include "ui_config.h" #include "utils.h" #include "vca_master_strip.h" @@ -467,7 +469,7 @@ VCAMasterStrip::build_context_menu () items.push_back (SeparatorElem()); items.push_back (MenuElem (_("Drop All Slaves"), sigc::mem_fun (*this, &VCAMasterStrip::drop_all_slaves))); items.push_back (SeparatorElem()); - items.push_back (MenuElem (_("Remove"), sigc::mem_fun (*this, &VCAMasterStrip::remove))); + items.push_back (MenuElem (_("Remove"), sigc::mem_fun(PublicEditor::instance(), &PublicEditor::remove_tracks))); } void @@ -492,16 +494,6 @@ VCAMasterStrip::spill_change (boost::shared_ptr vca) } } -void -VCAMasterStrip::remove () -{ - if (!_session) { - return; - } - - _session->vca_manager().remove_vca (_vca); -} - void VCAMasterStrip::assign_all_selected () {