1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-12-09 06:06:24 +01:00

Scrubbing phase 2. Scrub starts with click on the indicator in the ruler...

... and works in any of the six tools.

Click and drag in select tool during scrub works just as when not scrubbing.

Seeks now only if you left-click or drag in the ruler, but this may change.

Mouse motion anywhere on the screen controls scrub as before.

No mouse clicks in TrackPanel are used by scrubbing.

The Ctrl-Click in TrackPanel is now unused.  Should 2.1.0 behavior be restored?
That was click to quick play, redundant with click in the (lower part of) the
ruler.
This commit is contained in:
Paul Licameli
2016-04-24 19:02:13 -04:00
parent 4deb90c633
commit cd57e0a26c
6 changed files with 154 additions and 136 deletions

View File

@@ -55,9 +55,6 @@
#include "../Theme.h"
#include "../Experimental.h"
#ifdef EXPERIMENTAL_SCRUBBING_BASIC
#include "../tracks/ui/Scrubbing.h"
#endif
#include "../widgets/AButton.h"
@@ -87,21 +84,7 @@ ToolsToolBar::ToolsToolBar()
wxASSERT( drawTool == drawTool - firstTool );
wxASSERT( multiTool == multiTool - firstTool );
{
#ifdef EXPERIMENTAL_SCRUBBING_BASIC
mMessageOfTool[selectTool] =
#if defined(__WXMAC__)
_("Click and drag to select audio, Command-Click to scrub, Command-Double-Click to scroll-scrub, Command-drag to seek")
#else
_("Click and drag to select audio, Ctrl-Click to scrub, Ctrl-Double-Click to scroll-scrub, Ctrl-drag to seek")
#endif
;
#else
mMessageOfTool[selectTool] = _("Click and drag to select audio");
#endif
}
mMessageOfTool[selectTool] = _("Click and drag to select audio");
mMessageOfTool[envelopeTool] = _("Click and drag to edit the amplitude envelope");
mMessageOfTool[drawTool] = _("Click and drag to edit the samples");
@@ -219,14 +202,6 @@ void ToolsToolBar::SetCurrentTool(int tool, bool show)
//In multi-mode the current tool is shown by the
//cursor icon. The buttons are not updated.
#ifdef EXPERIMENTAL_SCRUBBING_BASIC
if (tool != selectTool) {
AudacityProject *const p = GetActiveProject();
if (p)
p->GetScrubber().StopScrubbing();
}
#endif
bool leavingMulticlipMode =
IsDown(multiTool) && show && tool != multiTool;
@@ -290,14 +265,6 @@ void ToolsToolBar::OnTool(wxCommandEvent & evt)
else
mTool[i]->PopUp();
#ifdef EXPERIMENTAL_SCRUBBING_BASIC
if (0 != mCurrentTool) {
AudacityProject *const p = GetActiveProject();
if (p)
p->GetScrubber().StopScrubbing();
}
#endif
RedrawAllProjects();
gPrefs->Write(wxT("/GUI/ToolBars/Tools/MultiToolActive"),