diff options
Diffstat (limited to 'gtk2_ardour')
-rw-r--r-- | gtk2_ardour/mixer_ui.cc | 29 | ||||
-rw-r--r-- | gtk2_ardour/mixer_ui.h | 3 |
2 files changed, 23 insertions, 9 deletions
diff --git a/gtk2_ardour/mixer_ui.cc b/gtk2_ardour/mixer_ui.cc index 1e2dd71b37..20dadf672f 100644 --- a/gtk2_ardour/mixer_ui.cc +++ b/gtk2_ardour/mixer_ui.cc @@ -3477,16 +3477,27 @@ void Mixer_UI::show_spill (boost::shared_ptr<Stripable> s) { boost::shared_ptr<Stripable> ss = spilled_strip.lock(); - if (ss != s) { - spilled_strip = s; - show_spill_change (s); /* EMIT SIGNAL */ - if (s) { - _group_tabs->hide (); - } else { - _group_tabs->show (); - } - redisplay_track_list (); + if (ss == s) { + return; + } + + spilled_strip = s; + _spill_gone_connection.disconnect (); + show_spill_change (s); /* EMIT SIGNAL */ + + if (s) { + s->DropReferences.connect (_spill_gone_connection, invalidator (*this), boost::bind (&Mixer_UI::spill_nothing, this), gui_context()); + _group_tabs->hide (); + } else { + _group_tabs->show (); } + redisplay_track_list (); +} + +void +Mixer_UI::spill_nothing () +{ + show_spill (boost::shared_ptr<Stripable> ()); } bool diff --git a/gtk2_ardour/mixer_ui.h b/gtk2_ardour/mixer_ui.h index 7992824b09..6af766ab6b 100644 --- a/gtk2_ardour/mixer_ui.h +++ b/gtk2_ardour/mixer_ui.h @@ -431,6 +431,9 @@ private: RouteProcessorSelection _selection; AxisViewSelection _axis_targets; + void spill_nothing (); + PBD::ScopedConnection _spill_gone_connection; + void vca_assign (boost::shared_ptr<ARDOUR::VCA>); void vca_unassign (boost::shared_ptr<ARDOUR::VCA>); |