summaryrefslogtreecommitdiff
path: root/libs/ardour/session.cc
diff options
context:
space:
mode:
Diffstat (limited to 'libs/ardour/session.cc')
-rw-r--r--libs/ardour/session.cc12
1 files changed, 12 insertions, 0 deletions
diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc
index a7fc6740c2..5744b55c65 100644
--- a/libs/ardour/session.cc
+++ b/libs/ardour/session.cc
@@ -537,11 +537,17 @@ Session::when_engine_running ()
BootMessage (_("Setup signal flow and plugins"));
+ /* this will cause the CPM to instantiate any protocols that are in use
+ * (or mandatory), which will pass it this Session, and then call
+ * set_state() on each instantiated protocol to match stored state.
+ */
+
ControlProtocolManager::instance().set_session (this);
/* This must be done after the ControlProtocolManager set_session above,
as it will set states for ports which the ControlProtocolManager creates.
*/
+
MIDI::Manager::instance()->set_port_states (Config->midi_port_states ());
/* And this must be done after the MIDI::Manager::set_port_states as
@@ -550,6 +556,12 @@ Session::when_engine_running ()
hookup_io ();
+ /* Let control protocols know that we are now all connected, so they
+ * could start talking to surfaces if they want to.
+ */
+
+ ControlProtocolManager::instance().midi_connectivity_established ();
+
if (_is_new && !no_auto_connect()) {
Glib::Mutex::Lock lm (AudioEngine::instance()->process_lock());
auto_connect_master_bus ();