diff --git a/src/AudioIO.cpp b/src/AudioIO.cpp index fc5709498..234a83758 100644 --- a/src/AudioIO.cpp +++ b/src/AudioIO.cpp @@ -2593,7 +2593,7 @@ void AudioIO::StopStream() while( mAudioThreadShouldCallFillBuffersOnce ) { // LLL: Experienced recursive yield here...once. - wxGetApp().Yield(true); // Pass true for onlyIfNeeded to avoid recursive call error. + wxTheApp->Yield(true); // Pass true for onlyIfNeeded to avoid recursive call error. wxMilliSleep( 50 ); } diff --git a/src/Screenshot.cpp b/src/Screenshot.cpp index 6b25a2b06..a23bdc123 100644 --- a/src/Screenshot.cpp +++ b/src/Screenshot.cpp @@ -39,7 +39,6 @@ It forwards the actual work of doing the commands to the ScreenshotCommand. #include #include -#include "AudacityApp.h" #include "Project.h" #include "Prefs.h" #include "toolbars/ToolManager.h" @@ -114,7 +113,7 @@ ScreenFramePtr mFrame; void OpenScreenshotTools() { if (!mFrame) { - auto parent = wxGetApp().GetTopWindow(); + auto parent = wxTheApp->GetTopWindow(); if (!parent) { wxASSERT(false); return; diff --git a/src/export/ExportFFmpegDialogs.cpp b/src/export/ExportFFmpegDialogs.cpp index 8ec333543..1b4526bb9 100644 --- a/src/export/ExportFFmpegDialogs.cpp +++ b/src/export/ExportFFmpegDialogs.cpp @@ -64,7 +64,6 @@ #include "../Tags.h" #include "../TranslatableStringArray.h" #include "../widgets/ErrorDialog.h" -#include "../AudacityApp.h" #include "Export.h" @@ -471,7 +470,7 @@ void ExportFFmpegCustomOptions::OnOpen(wxCommandEvent & WXUNUSED(evt)) } } DropFFmpegLibs(); - auto pWin = wxGetApp().GetTopWindow(); + auto pWin = wxTheApp->GetTopWindow(); ExportFFmpegOptions od(pWin); od.ShowModal(); } diff --git a/src/export/ExportPCM.cpp b/src/export/ExportPCM.cpp index 0d581df1b..2e4e01fee 100644 --- a/src/export/ExportPCM.cpp +++ b/src/export/ExportPCM.cpp @@ -25,7 +25,6 @@ #include "sndfile.h" -#include "../AudacityApp.h" // for error reporting top level window. #include "../FileFormats.h" #include "../Internat.h" #include "../MemoryX.h" @@ -520,7 +519,7 @@ ProgressResult ExportPCM::Export(AudacityProject *project, // Test for 4 Gibibytes, rather than 4 Gigabytes if( byteCount > 4.295e9) { - ReportTooBigError( wxGetApp().GetTopWindow() ); + ReportTooBigError( wxTheApp->GetTopWindow() ); return ProgressResult::Failed; } diff --git a/src/menus/HelpMenus.cpp b/src/menus/HelpMenus.cpp index edd8e5fa4..3b4dab392 100644 --- a/src/menus/HelpMenus.cpp +++ b/src/menus/HelpMenus.cpp @@ -215,7 +215,7 @@ static CommandHandlerObject &findCommandHandler(AudacityProject &) { MenuTable::BaseItemPtr HelpMenu( AudacityProject & ) { #ifdef __WXMAC__ - wxGetApp().s_macHelpMenuTitleName = _("&Help"); + wxApp::s_macHelpMenuTitleName = _("&Help"); #endif using namespace MenuTable;