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

Method OnExit

src/AudacityApp.cpp:2521–2561  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2519}
2520
2521int AudacityApp::OnExit()
2522{
2523 gIsQuitting = true;
2524 while(Pending())
2525 {
2526 Dispatch();
2527 }
2528
2529 HandleAppClosing();
2530
2531 Importer::Get().Terminate();
2532
2533 if(gPrefs)
2534 {
2535 bool bFalse = false;
2536 //Should we change the commands.cfg location next startup?
2537 if(gPrefs->Read(wxT("/QDeleteCmdCfgLocation"), &bFalse))
2538 {
2539 gPrefs->DeleteEntry(wxT("/QDeleteCmdCfgLocation"));
2540 gPrefs->Write(wxT("/DeleteCmdCfgLocation"), true);
2541 gPrefs->Flush();
2542 }
2543 }
2544
2545 FileHistory::Global().Save(*gPrefs);
2546
2547 FinishPreferences();
2548
2549 DeinitFFT();
2550
2551#ifdef HAS_NETWORKING
2552 audacity::network_manager::NetworkManager::GetInstance().Terminate();
2553#endif
2554
2555 AudioIO::Deinit();
2556
2557 // Terminate the PluginManager (must be done before deleting the locale)
2558 PluginManager::Get().Terminate();
2559
2560 return 0;
2561}
2562
2563// The following five methods are currently only used on Mac OS,
2564// where it's possible to have a menu bar but no windows open.

Callers

nothing calls this directly

Calls 10

GetFunction · 0.85
FinishPreferencesFunction · 0.85
DeinitFFTFunction · 0.85
DispatchFunction · 0.50
TerminateMethod · 0.45
ReadMethod · 0.45
DeleteEntryMethod · 0.45
WriteMethod · 0.45
FlushMethod · 0.45
SaveMethod · 0.45

Tested by

no test coverage detected