mirror of
https://github.com/cookiengineer/audacity
synced 2025-11-23 17:30:17 +01:00
More exception-safety for recording...
... Do not call Autosave (which might fail) when recovering from exceptions in recording, but rely on the last good Autosave that happened during recording. If dropout labels are needed, then immediately modify the undo history item, but we can accept it if that modification fails. Also, be sure NOT to skip Autosave in all other places that push the undo history. Make Autosave the default unless otherwise specified. Finally removed one unnecessary call to Autosave.
This commit is contained in:
@@ -168,7 +168,7 @@ void DoPanTracks(AudacityProject &project, float PanValue)
|
||||
for (auto left : count == 0 ? range : selectedRange )
|
||||
left->SetPan( PanValue );
|
||||
|
||||
auto flags = UndoPush::AUTOSAVE;
|
||||
auto flags = UndoPush::NONE;
|
||||
ProjectHistory::Get( project )
|
||||
/*i18n-hint: One or more audio tracks have been panned*/
|
||||
.PushState(XO("Panned audio track(s)"), XO("Pan Track"), flags);
|
||||
@@ -799,7 +799,7 @@ void OnResample(const CommandContext &context)
|
||||
}
|
||||
|
||||
int ndx = 0;
|
||||
auto flags = UndoPush::AUTOSAVE;
|
||||
auto flags = UndoPush::NONE;
|
||||
for (auto wt : tracks.Selected< WaveTrack >())
|
||||
{
|
||||
auto msg = XO("Resampling track %d").Format( ++ndx );
|
||||
|
||||
Reference in New Issue
Block a user