diff options
author | Len Ovens <len@ovenwerks.net> | 2017-07-30 18:34:56 -0700 |
---|---|---|
committer | Len Ovens <len@ovenwerks.net> | 2017-07-30 18:35:38 -0700 |
commit | e94771a58fcab23c1c5e3c0bf6a191a66e4e06e1 (patch) | |
tree | 9ea33a049dbef659b6054743e4a129d01395897a | |
parent | 008c3db9cd9c7e9d5a1c314e15c917c72289bd26 (diff) |
OSC: fix VCAs try to connect to controls it does not have.
-rw-r--r-- | libs/surfaces/osc/osc_route_observer.cc | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/libs/surfaces/osc/osc_route_observer.cc b/libs/surfaces/osc/osc_route_observer.cc index 550fd396a0..656c6f086e 100644 --- a/libs/surfaces/osc/osc_route_observer.cc +++ b/libs/surfaces/osc/osc_route_observer.cc @@ -61,11 +61,15 @@ OSCRouteObserver::OSCRouteObserver (boost::shared_ptr<Stripable> s, uint32_t ss, _strip->solo_control()->Changed.connect (strip_connections, MISSING_INVALIDATOR, boost::bind (&OSCRouteObserver::send_change_message, this, X_("/strip/solo"), _strip->solo_control()), OSC::instance()); send_change_message ("/strip/solo", _strip->solo_control()); - _strip->solo_isolate_control()->Changed.connect (strip_connections, MISSING_INVALIDATOR, bind (&OSCRouteObserver::send_change_message, this, X_("/strip/solo_iso"), _strip->solo_isolate_control()), OSC::instance()); - send_change_message ("/strip/solo_iso", _strip->solo_isolate_control()); + if (_strip->solo_isolate_control()) { + _strip->solo_isolate_control()->Changed.connect (strip_connections, MISSING_INVALIDATOR, bind (&OSCRouteObserver::send_change_message, this, X_("/strip/solo_iso"), _strip->solo_isolate_control()), OSC::instance()); + send_change_message ("/strip/solo_iso", _strip->solo_isolate_control()); + } - _strip->solo_safe_control()->Changed.connect (strip_connections, MISSING_INVALIDATOR, bind (&OSCRouteObserver::send_change_message, this, X_("/strip/solo_safe"), _strip->solo_safe_control()), OSC::instance()); - send_change_message ("/strip/solo_safe", _strip->solo_safe_control()); + if (_strip->solo_safe_control()) { + _strip->solo_safe_control()->Changed.connect (strip_connections, MISSING_INVALIDATOR, bind (&OSCRouteObserver::send_change_message, this, X_("/strip/solo_safe"), _strip->solo_safe_control()), OSC::instance()); + send_change_message ("/strip/solo_safe", _strip->solo_safe_control()); + } boost::shared_ptr<Track> track = boost::dynamic_pointer_cast<Track> (_strip); if (track) { |