From 530a4393dc0004996a1979c855e2363b8fd8e0a2 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Mon, 18 Nov 2019 21:29:32 -0700 Subject: [PATCH] fix transport FSM to stop first and declick later --- libs/ardour/ardour/transport_fsm.h | 1 - libs/ardour/transport_fsm.cc | 12 ++---------- 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/libs/ardour/ardour/transport_fsm.h b/libs/ardour/ardour/transport_fsm.h index 2378d1f09d..7eafccead1 100644 --- a/libs/ardour/ardour/transport_fsm.h +++ b/libs/ardour/ardour/transport_fsm.h @@ -138,7 +138,6 @@ struct TransportFSM void start_locate_while_stopped (Event const &) const; void interrupt_locate (Event const &) const; void start_declick_for_locate (Event const &); - void start_declick_for_stop (Event const &); /* guards */ diff --git a/libs/ardour/transport_fsm.cc b/libs/ardour/transport_fsm.cc index 16f6de99a6..d1a56cf101 100644 --- a/libs/ardour/transport_fsm.cc +++ b/libs/ardour/transport_fsm.cc @@ -231,7 +231,7 @@ TransportFSM::process_event (Event& ev, bool already_deferred, bool& deferred) switch (_motion_state) { case Rolling: transition (DeclickToStop); - start_declick_for_stop (ev); + stop_playback (); break; case Stopped: break; @@ -316,7 +316,7 @@ TransportFSM::process_event (Event& ev, bool already_deferred, bool& deferred) break; case DeclickToStop: transition (Stopped); - stop_playback (); + /* transport already stopped */ break; default: bad_transition (ev); return false; @@ -375,14 +375,6 @@ TransportFSM::stop_playback () api->stop_transport (_last_stop.abort, _last_stop.clear_state); } -void -TransportFSM::start_declick_for_stop (Event const & s) -{ - assert (s.type == StopTransport); - DEBUG_TRACE (DEBUG::TFSMEvents, "start_declick_for_stop\n"); - _last_stop = s; -} - void TransportFSM::set_roll_after (bool with_roll) const {