Re-add global lookup for generic-midi ctrl state
This commit is contained in:
parent
087fd57d37
commit
73029d45ba
@ -631,7 +631,7 @@ GenericMidiControlProtocol::set_state (const XMLNode& node, int version)
|
||||
if ((*niter)->get_property ("id", id)) {
|
||||
|
||||
DEBUG_TRACE (DEBUG::GenericMidi, string_compose ("Relearned binding for session: Control ID: %1\n", id.to_s()));
|
||||
boost::shared_ptr<PBD::Controllable> c = session->controllable_by_id (id); // XXX are these all?
|
||||
boost::shared_ptr<PBD::Controllable> c = Controllable::by_id (id);
|
||||
|
||||
if (c) {
|
||||
MIDIControllable* mc = new MIDIControllable (this, *_input_port->parser(), c, false);
|
||||
|
@ -144,7 +144,6 @@ MIDIControllable::set_controllable (boost::shared_ptr<PBD::Controllable> c)
|
||||
last_incoming = 256;
|
||||
|
||||
if (c) {
|
||||
printf ("MIDIControllable::set %s\n", c->name().c_str());
|
||||
c->Destroyed.connect_same_thread (controllable_death_connection,
|
||||
boost::bind (&MIDIControllable::drop_controllable, this, _1));
|
||||
}
|
||||
@ -278,8 +277,6 @@ MIDIControllable::lookup_controllable()
|
||||
void
|
||||
MIDIControllable::drop_controllable (Controllable* c)
|
||||
{
|
||||
printf ("MIDIControllable::drop_controllable ? %s\n", c->name().c_str());
|
||||
|
||||
boost::shared_ptr<Controllable> controllable = _controllable.lock ();
|
||||
if (controllable && c == controllable.get()) {
|
||||
set_controllable (boost::shared_ptr<PBD::Controllable>());
|
||||
|
Loading…
Reference in New Issue
Block a user