1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-06-15 23:59:37 +02:00

Lowered check for scrubbing into GetMessageForTool...

... which is called only in one place
This commit is contained in:
Paul Licameli 2017-06-14 09:22:37 -04:00
parent 23e3aeba35
commit 55dc096896
2 changed files with 7 additions and 4 deletions

View File

@ -1763,9 +1763,7 @@ void TrackPanel::HandleCursor(const wxMouseEvent & event)
// practice (on a P500).
int tool = DetermineToolToUse( ttb, event );
tip = GetProject()->GetScrubber().StatusMessageForWave();
if( tip.IsEmpty() )
tip = ttb->GetMessageForTool(tool);
tip = ttb->GetMessageForTool(tool);
if( tool != selectTool )
{

View File

@ -52,6 +52,7 @@
#include "../AllThemeResources.h"
#include "../ImageManipulation.h"
#include "../Project.h"
#include "../tracks/ui/Scrubbing.h"
#include "../Theme.h"
#include "../Experimental.h"
@ -269,7 +270,11 @@ const wxChar * ToolsToolBar::GetMessageForTool( int ToolNumber ) const
wxASSERT( ToolNumber >= 0 );
wxASSERT( ToolNumber < numTools );
return mMessageOfTool[ToolNumber];
auto tip = ::GetActiveProject()->GetScrubber().StatusMessageForWave();
if( tip.IsEmpty() )
return mMessageOfTool[ToolNumber];
else
return tip;
}