summaryrefslogtreecommitdiff
path: root/libs/ardour/mtc_slave.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2019-09-17 18:26:03 -0600
committerPaul Davis <paul@linuxaudiosystems.com>2019-09-17 18:26:03 -0600
commitbd229936ec2cb30fe3360f2d83ffc7197fd6fb97 (patch)
tree84e41e048d76541d5d491ccefe8c7feaa14f4d5c /libs/ardour/mtc_slave.cc
parentfc3e7623e7a4c7fdeebf84c4d47eaf04d9bc744d (diff)
add finite state machine to control/manage transport state
Diffstat (limited to 'libs/ardour/mtc_slave.cc')
-rw-r--r--libs/ardour/mtc_slave.cc12
1 files changed, 8 insertions, 4 deletions
diff --git a/libs/ardour/mtc_slave.cc b/libs/ardour/mtc_slave.cc
index 3f045e26d4..048ac95455 100644
--- a/libs/ardour/mtc_slave.cc
+++ b/libs/ardour/mtc_slave.cc
@@ -68,10 +68,6 @@ MTC_TransportMaster::MTC_TransportMaster (std::string const & name)
, busy_guard2 (0)
, printed_timecode_warning (false)
{
- if ((_port = create_midi_port (string_compose ("%1 in", name))) == 0) {
- throw failed_constructor();
- }
-
DEBUG_TRACE (DEBUG::Slave, string_compose ("MTC registered %1\n", _port->name()));
init ();
@@ -104,6 +100,14 @@ MTC_TransportMaster::init ()
}
void
+MTC_TransportMaster::create_port ()
+{
+ if ((_port = create_midi_port (string_compose ("%1 in", _name))) == 0) {
+ throw failed_constructor();
+ }
+}
+
+void
MTC_TransportMaster::set_session (Session *s)
{
config_connection.disconnect ();