mirror of
https://github.com/cookiengineer/audacity
synced 2025-10-26 23:33:49 +01:00
New attached structure ProjectManager handles project lifetime...
... that is, a factory function, open, close, import, undo/redo/rollback. Also the callbacks from AudioIO, which need to invoke undo history push when recording stops. It is meant as a high-level class using several of the other things attached to the project, while AudacityProject will be a low level class acting mostly as just the container of the attached structures.
This commit is contained in:
@@ -461,7 +461,7 @@ void ApplyMacroDialog::OnApplyToFiles(wxCommandEvent & WXUNUSED(event))
|
||||
fileList->EnsureVisible(i);
|
||||
|
||||
auto success = GuardedCall< bool >( [&] {
|
||||
project->Import(files[i]);
|
||||
ProjectManager::Get( *project ).Import(files[i]);
|
||||
ProjectWindow::Get( *project ).ZoomAfterImport(nullptr);
|
||||
SelectActions::DoSelectAll(*project);
|
||||
if (!mMacroCommands.ApplyMacro(mCatalog))
|
||||
@@ -476,7 +476,7 @@ void ApplyMacroDialog::OnApplyToFiles(wxCommandEvent & WXUNUSED(event))
|
||||
if (!success)
|
||||
break;
|
||||
|
||||
project->ResetProjectToEmpty();
|
||||
ProjectManager::Get( *project ).ResetProjectToEmpty();
|
||||
}
|
||||
|
||||
Show();
|
||||
|
||||
Reference in New Issue
Block a user