From f610db9e2744f5d9a54de4cc2edb84d10504715e Mon Sep 17 00:00:00 2001 From: madisonsilver Date: Sat, 18 Feb 2023 18:01:11 -0800 Subject: [PATCH] Fix issues #6383 and #4410 (pause issues). (#6590) Fixes #6383 and fixes #4410. Co-authored-by: Hyunjin Song --- src/core/Song.cpp | 1 + src/gui/editors/PianoRoll.cpp | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/core/Song.cpp b/src/core/Song.cpp index 06ac15633de..fef66f1932d 100644 --- a/src/core/Song.cpp +++ b/src/core/Song.cpp @@ -620,6 +620,7 @@ void Song::togglePause() { m_playing = false; m_paused = true; + Engine::audioEngine()->clear(); } m_vstSyncController.setPlaybackState( m_playing ); diff --git a/src/gui/editors/PianoRoll.cpp b/src/gui/editors/PianoRoll.cpp index 1dbbe1cf4c2..d4781eccd0a 100644 --- a/src/gui/editors/PianoRoll.cpp +++ b/src/gui/editors/PianoRoll.cpp @@ -858,8 +858,7 @@ void PianoRoll::setCurrentMidiClip( MidiClip* newMidiClip ) } // force the song-editor to stop playing if it played a MIDI clip before - if( Engine::getSong()->isPlaying() && - Engine::getSong()->playMode() == Song::Mode_PlayMidiClip ) + if (Engine::getSong()->playMode() == Song::Mode_PlayMidiClip) { Engine::getSong()->playMidiClip( nullptr ); }