MCPcopy Create free account
hub / github.com/audacity/audacity / RecoverAllProjects

Function RecoverAllProjects

src/AutoRecoveryDialog.cpp:419–441  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

417////////////////////////////////////////////////////////////////////////////
418
419static bool RecoverAllProjects(const FilePaths &files,
420 AudacityProject *&pproj)
421{
422 // Open a project window for each auto save file
423 wxString filename;
424 bool result = true;
425
426 for (auto &file: files)
427 {
428 AudacityProject *proj = nullptr;
429 // Reuse any existing project window, which will be the empty project
430 // created at application startup
431 std::swap(proj, pproj);
432
433 // Open project.
434 if (ProjectManager::OpenProject(proj, file, false, true) == nullptr)
435 {
436 result = false;
437 }
438 }
439
440 return result;
441}
442
443static void DiscardAllProjects(const FilePaths &files)
444{

Callers 1

Calls 1

swapFunction · 0.50

Tested by

no test coverage detected