1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-08-07 23:51:14 +02:00

Merge branch 'scrubbing2'

* scrubbing2:
  Correct switching between scrub and seek in progress
This commit is contained in:
Paul Licameli 2016-06-15 23:50:54 -04:00
commit 2ad26e586f

View File

@ -808,14 +808,17 @@ void Scrubber::DoScrub()
void Scrubber::OnScrubOrSeek(bool seek)
{
mSeeking = seek;
bool skip = false;
if (HasStartedScrubbing()) {
skip = (mSeeking != seek); // just switching mode
// Show the correct status.
const auto ctb = mProject->GetControlToolBar();
ctb->UpdateStatusBar(mProject);
}
mSeeking = seek;
auto ruler = mProject->GetRulerPanel();
if (ruler)
// Update button images
@ -825,7 +828,8 @@ void Scrubber::OnScrubOrSeek(bool seek)
scrubbingToolBar->EnableDisableButtons();
scrubbingToolBar->RegenerateTooltips();
DoScrub();
if (!skip)
DoScrub();
CheckMenuItems();
}