diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2017-01-27 19:18:33 +0100 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2017-01-27 22:17:53 +0100 |
commit | cc82fc675b096c3dfec76d0c45671b78c85007cf (patch) | |
tree | 4acd88079a01f3f52f624818186c6db14b83e0c7 /gtk2_ardour/route_processor_selection.cc | |
parent | 4821def1736c55866fc6f354dcd98a61c3451101 (diff) |
remove editor/mixer selection change signals; make editor and mixer use PresentationInfo::Change more correctly; make Selection a bit smarter when setting track selection
Diffstat (limited to 'gtk2_ardour/route_processor_selection.cc')
-rw-r--r-- | gtk2_ardour/route_processor_selection.cc | 25 |
1 files changed, 3 insertions, 22 deletions
diff --git a/gtk2_ardour/route_processor_selection.cc b/gtk2_ardour/route_processor_selection.cc index 7428267b50..6b7592efd4 100644 --- a/gtk2_ardour/route_processor_selection.cc +++ b/gtk2_ardour/route_processor_selection.cc @@ -32,7 +32,7 @@ using namespace std; using namespace ARDOUR; using namespace PBD; -unsigned int RouteProcessorSelection::_no_route_change_signal = 0; + RouteProcessorSelection::RouteProcessorSelection() { } @@ -71,14 +71,13 @@ RouteProcessorSelection::clear_processors () void RouteProcessorSelection::clear_routes () { + PresentationInfo::ChangeSuspender cs; + for (AxisViewSelection::iterator i = axes.begin(); i != axes.end(); ++i) { (*i)->set_selected (false); } axes.clear (); drop_connections (); - if (0 == _no_route_change_signal) { - RoutesChanged (); - } } void @@ -109,10 +108,6 @@ RouteProcessorSelection::add (AxisView* r) if (ms) { ms->CatchDeletion.connect (*this, invalidator (*this), boost::bind (&RouteProcessorSelection::remove, this, _1), gui_context()); } - - if (0 == _no_route_change_signal) { - RoutesChanged(); - } } } @@ -125,9 +120,6 @@ RouteProcessorSelection::remove (AxisView* r) if ((i = find (axes.begin(), axes.end(), r)) != axes.end()) { (*i)->set_selected (false); axes.erase (i); - if (0 == _no_route_change_signal) { - RoutesChanged (); - } } } @@ -149,14 +141,3 @@ RouteProcessorSelection::empty () { return processors.empty () && axes.empty (); } - -void -RouteProcessorSelection::block_routes_changed (bool yn) -{ - if (yn) { - ++_no_route_change_signal; - } else { - assert (_no_route_change_signal > 0); - --_no_route_change_signal; - } -} |