mirror of
https://github.com/cookiengineer/audacity
synced 2025-12-17 22:21:17 +01:00
New attached structure ProjectFileIO handles load and save
This commit is contained in:
@@ -184,26 +184,30 @@ void OnClose(const CommandContext &context )
|
||||
void OnSave(const CommandContext &context )
|
||||
{
|
||||
auto &project = context.project;
|
||||
project.Save();
|
||||
auto &projectFileIO = ProjectFileIO::Get( project );
|
||||
projectFileIO.Save();
|
||||
}
|
||||
|
||||
void OnSaveAs(const CommandContext &context )
|
||||
{
|
||||
auto &project = context.project;
|
||||
project.SaveAs();
|
||||
auto &projectFileIO = ProjectFileIO::Get( project );
|
||||
projectFileIO.SaveAs();
|
||||
}
|
||||
|
||||
void OnSaveCopy(const CommandContext &context )
|
||||
{
|
||||
auto &project = context.project;
|
||||
project.SaveAs(true, true);
|
||||
auto &projectFileIO = ProjectFileIO::Get( project );
|
||||
projectFileIO.SaveAs(true, true);
|
||||
}
|
||||
|
||||
#ifdef USE_LIBVORBIS
|
||||
void OnSaveCompressed(const CommandContext &context)
|
||||
{
|
||||
auto &project = context.project;
|
||||
project.SaveAs(true);
|
||||
auto &projectFileIO = ProjectFileIO::Get( project );
|
||||
projectFileIO.SaveAs(true);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
@@ -432,7 +432,7 @@ void OnTimerRecord(const CommandContext &context)
|
||||
}
|
||||
// We use this variable to display "Current Project" in the Timer Recording
|
||||
// save project field
|
||||
bool bProjectSaved = project.IsProjectSaved();
|
||||
bool bProjectSaved = ProjectFileIO::Get( project ).IsProjectSaved();
|
||||
|
||||
//we break the prompting and waiting dialogs into two sections
|
||||
//because they both give the user a chance to click cancel
|
||||
|
||||
Reference in New Issue
Block a user