1
0
mirror of https://github.com/cookiengineer/audacity synced 2026-02-07 04:01:54 +01:00

Split class ProjectFileManager from ProjectFileIO...

... The former will handle File menu items, and the choosing of file paths to
write; the latter will handle the XML contents and do auto-save.  Auto-save is
a lower-level thing that must be done in many places whenever undo history
is pushed or modified.
This commit is contained in:
Paul Licameli
2019-06-07 13:24:38 -04:00
parent e84dae4093
commit 4bf3365af4
6 changed files with 145 additions and 89 deletions

View File

@@ -622,12 +622,12 @@ int TimerRecordDialog::ExecutePostRecordActions(bool bWasStopped) {
// Do Automatic Save?
if (m_bAutoSaveEnabled) {
auto &projectFileIO = ProjectFileIO::Get( *pProject );
auto &projectFileManager = ProjectFileManager::Get( *pProject );
// MY: If this project has already been saved then simply execute a Save here
if (m_bProjectAlreadySaved) {
bSaveOK = projectFileIO.Save();
bSaveOK = projectFileManager.Save();
} else {
bSaveOK = projectFileIO.SaveFromTimerRecording(m_fnAutoSaveFile);
bSaveOK = projectFileManager.SaveFromTimerRecording(m_fnAutoSaveFile);
}
}