mirror of
https://github.com/cookiengineer/audacity
synced 2026-04-24 23:13:42 +02:00
Don't reuse EditActions::DoUndo...
... instead, when timer recording is cancelled, don't push state and pop it at once, but just roll it back.
This commit is contained in:
@@ -235,8 +235,13 @@ bool DoEditMetadata
|
||||
return false;
|
||||
}
|
||||
|
||||
void DoUndo(AudacityProject &project)
|
||||
// Menu handler functions
|
||||
|
||||
struct Handler : CommandHandlerObject {
|
||||
|
||||
void OnUndo(const CommandContext &context)
|
||||
{
|
||||
auto &project = context.project;
|
||||
auto &trackPanel = TrackPanel::Get( project );
|
||||
auto &undoManager = UndoManager::Get( project );
|
||||
auto &window = ProjectWindow::Get( project );
|
||||
@@ -257,16 +262,6 @@ void DoUndo(AudacityProject &project)
|
||||
|
||||
trackPanel.EnsureVisible(trackPanel.GetFirstSelectedTrack());
|
||||
}
|
||||
|
||||
// Menu handler functions
|
||||
|
||||
struct Handler : CommandHandlerObject {
|
||||
|
||||
void OnUndo(const CommandContext &context)
|
||||
{
|
||||
DoUndo(context.project);
|
||||
}
|
||||
|
||||
void OnRedo(const CommandContext &context)
|
||||
{
|
||||
auto &project = context.project;
|
||||
|
||||
Reference in New Issue
Block a user