mirror of
https://github.com/cookiengineer/audacity
synced 2025-06-16 16:10:06 +02:00
Fix bug 680
"Project was recovered" replaces "Create new project" in Undo History.
This commit is contained in:
parent
93bb862aa2
commit
75fdadf674
@ -103,13 +103,13 @@ HistoryWindow::HistoryWindow(AudacityProject *parent, UndoManager *manager):
|
||||
[](wxEvent&){});
|
||||
S.AddVariableText( {} )->Hide();
|
||||
|
||||
mAvail = S.Id(ID_AVAIL).AddTextBox(_("&Undo Levels Available"), wxT("0"), 10);
|
||||
mAvail = S.Id(ID_AVAIL).AddTextBox(_("&Undo levels available"), wxT("0"), 10);
|
||||
mAvail->Bind(wxEVT_KEY_DOWN,
|
||||
// ignore it
|
||||
[](wxEvent&){});
|
||||
S.AddVariableText( {} )->Hide();
|
||||
|
||||
S.AddPrompt(_("&Levels To Discard"));
|
||||
S.AddPrompt(_("&Levels to discard"));
|
||||
mLevels = safenew wxSpinCtrl(S.GetParent(),
|
||||
ID_LEVELS,
|
||||
wxT("1"),
|
||||
|
@ -898,6 +898,9 @@ AudacityProject *ProjectManager::OpenProject(
|
||||
if( projectFileIO.IsRecovered() ) {
|
||||
auto &window = ProjectWindow::Get( *pProject );
|
||||
window.Zoom( window.GetZoomOfToFit() );
|
||||
// "Project was recovered" replaces "Create new project" in Undo History.
|
||||
auto &undoManager = UndoManager::Get( *pProject );
|
||||
undoManager.RemoveStates(1);
|
||||
}
|
||||
|
||||
return pProject;
|
||||
|
Loading…
x
Reference in New Issue
Block a user