diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2010-03-30 15:18:43 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2010-03-30 15:18:43 +0000 |
commit | 14b0ca31bcb62e5b7e9e77634ef9cd2e8cf65800 (patch) | |
tree | 494bcf5351ff29d9981c22450863982b93a91a71 /gtk2_ardour/port_matrix.cc | |
parent | 10c257039df399fc5a9c383434ee19abab6199ed (diff) |
handle deletion of UI objects between the time that a callback is queued with the UI event loop and the execution of the callback (intrusive, big)
git-svn-id: svn://localhost/ardour2/branches/3.0@6807 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/port_matrix.cc')
-rw-r--r-- | gtk2_ardour/port_matrix.cc | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/gtk2_ardour/port_matrix.cc b/gtk2_ardour/port_matrix.cc index 209c4760f1..f26a78a722 100644 --- a/gtk2_ardour/port_matrix.cc +++ b/gtk2_ardour/port_matrix.cc @@ -136,10 +136,10 @@ PortMatrix::init () for (int i = 0; i < 2; ++i) { /* watch for the content of _ports[] changing */ - _ports[i].Changed.connect (_changed_connections, boost::bind (&PortMatrix::setup, this), gui_context()); + _ports[i].Changed.connect (_changed_connections, invalidator (*this), boost::bind (&PortMatrix::setup, this), gui_context()); /* and for bundles in _ports[] changing */ - _ports[i].BundleChanged.connect (_bundle_changed_connections, boost::bind (&PortMatrix::setup, this), gui_context()); + _ports[i].BundleChanged.connect (_bundle_changed_connections, invalidator (*this), boost::bind (&PortMatrix::setup, this), gui_context()); } /* scrolling stuff */ @@ -150,13 +150,13 @@ PortMatrix::init () /* Part 2: notice when things have changed that require our subclass to clear and refill _ports[] */ /* watch for routes being added or removed */ - _session->RouteAdded.connect (_session_connections, boost::bind (&PortMatrix::routes_changed, this), gui_context()); + _session->RouteAdded.connect (_session_connections, invalidator (*this), boost::bind (&PortMatrix::routes_changed, this), gui_context()); /* and also bundles */ - _session->BundleAdded.connect (_session_connections, boost::bind (&PortMatrix::setup_global_ports, this), gui_context()); + _session->BundleAdded.connect (_session_connections, invalidator (*this), boost::bind (&PortMatrix::setup_global_ports, this), gui_context()); /* and also ports */ - _session->engine().PortRegisteredOrUnregistered.connect (_session_connections, boost::bind (&PortMatrix::setup_global_ports, this), gui_context()); + _session->engine().PortRegisteredOrUnregistered.connect (_session_connections, invalidator (*this), boost::bind (&PortMatrix::setup_global_ports, this), gui_context()); reconnect_to_routes (); @@ -171,7 +171,7 @@ PortMatrix::reconnect_to_routes () boost::shared_ptr<RouteList> routes = _session->get_routes (); for (RouteList::iterator i = routes->begin(); i != routes->end(); ++i) { - (*i)->processors_changed.connect (_route_connections, ui_bind (&PortMatrix::route_processors_changed, this, _1), gui_context()); + (*i)->processors_changed.connect (_route_connections, invalidator (*this), ui_bind (&PortMatrix::route_processors_changed, this, _1), gui_context()); } } |