1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-10-15 23:21:12 +02:00

Do not store pause state in ControlToolBar...

... Move that into ProjectAudioManager instead, and update the button, only to
reflect it, in idle time.

However, AudioIO also has its mPaused member variable, and it is not obvious
that it was always kept the same as the button state.  No attempt was made
here to identify and fix any bugs, but only to preserve behavior.
This commit is contained in:
Paul Licameli
2019-07-01 10:19:09 -04:00
parent 8b549ea07f
commit 923128731d
4 changed files with 27 additions and 33 deletions

View File

@@ -869,9 +869,7 @@ void Scrubber::OnActivateOrDeactivateApp(wxActivateEvent &event)
// Pause if Pause down, or not scrubbing.
if (!mProject)
Pause(true);
else if ( !ControlToolBar::Find( *mProject ) )
Pause( true );
else if (ControlToolBar::Get( *mProject ).IsPauseDown())
else if (ProjectAudioManager::Get( *mProject ).Paused())
Pause( true );
else if (!IsScrubbing())
Pause( true );