mirror of
https://github.com/cookiengineer/audacity
synced 2025-07-26 09:28:07 +02:00
Don't use AudacityApp where you only need wxApp...
... I want to have fewer inclusions of AudacityApp.h. More work on removing them will happen in the next version.
This commit is contained in:
parent
21a1260f91
commit
544d9aa580
@ -2593,7 +2593,7 @@ void AudioIO::StopStream()
|
|||||||
while( mAudioThreadShouldCallFillBuffersOnce )
|
while( mAudioThreadShouldCallFillBuffersOnce )
|
||||||
{
|
{
|
||||||
// LLL: Experienced recursive yield here...once.
|
// 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 );
|
wxMilliSleep( 50 );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -39,7 +39,6 @@ It forwards the actual work of doing the commands to the ScreenshotCommand.
|
|||||||
#include <wx/tglbtn.h>
|
#include <wx/tglbtn.h>
|
||||||
#include <wx/window.h>
|
#include <wx/window.h>
|
||||||
|
|
||||||
#include "AudacityApp.h"
|
|
||||||
#include "Project.h"
|
#include "Project.h"
|
||||||
#include "Prefs.h"
|
#include "Prefs.h"
|
||||||
#include "toolbars/ToolManager.h"
|
#include "toolbars/ToolManager.h"
|
||||||
@ -114,7 +113,7 @@ ScreenFramePtr mFrame;
|
|||||||
void OpenScreenshotTools()
|
void OpenScreenshotTools()
|
||||||
{
|
{
|
||||||
if (!mFrame) {
|
if (!mFrame) {
|
||||||
auto parent = wxGetApp().GetTopWindow();
|
auto parent = wxTheApp->GetTopWindow();
|
||||||
if (!parent) {
|
if (!parent) {
|
||||||
wxASSERT(false);
|
wxASSERT(false);
|
||||||
return;
|
return;
|
||||||
|
@ -64,7 +64,6 @@
|
|||||||
#include "../Tags.h"
|
#include "../Tags.h"
|
||||||
#include "../TranslatableStringArray.h"
|
#include "../TranslatableStringArray.h"
|
||||||
#include "../widgets/ErrorDialog.h"
|
#include "../widgets/ErrorDialog.h"
|
||||||
#include "../AudacityApp.h"
|
|
||||||
|
|
||||||
#include "Export.h"
|
#include "Export.h"
|
||||||
|
|
||||||
@ -471,7 +470,7 @@ void ExportFFmpegCustomOptions::OnOpen(wxCommandEvent & WXUNUSED(evt))
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
DropFFmpegLibs();
|
DropFFmpegLibs();
|
||||||
auto pWin = wxGetApp().GetTopWindow();
|
auto pWin = wxTheApp->GetTopWindow();
|
||||||
ExportFFmpegOptions od(pWin);
|
ExportFFmpegOptions od(pWin);
|
||||||
od.ShowModal();
|
od.ShowModal();
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,6 @@
|
|||||||
|
|
||||||
#include "sndfile.h"
|
#include "sndfile.h"
|
||||||
|
|
||||||
#include "../AudacityApp.h" // for error reporting top level window.
|
|
||||||
#include "../FileFormats.h"
|
#include "../FileFormats.h"
|
||||||
#include "../Internat.h"
|
#include "../Internat.h"
|
||||||
#include "../MemoryX.h"
|
#include "../MemoryX.h"
|
||||||
@ -520,7 +519,7 @@ ProgressResult ExportPCM::Export(AudacityProject *project,
|
|||||||
// Test for 4 Gibibytes, rather than 4 Gigabytes
|
// Test for 4 Gibibytes, rather than 4 Gigabytes
|
||||||
if( byteCount > 4.295e9)
|
if( byteCount > 4.295e9)
|
||||||
{
|
{
|
||||||
ReportTooBigError( wxGetApp().GetTopWindow() );
|
ReportTooBigError( wxTheApp->GetTopWindow() );
|
||||||
return ProgressResult::Failed;
|
return ProgressResult::Failed;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -215,7 +215,7 @@ static CommandHandlerObject &findCommandHandler(AudacityProject &) {
|
|||||||
MenuTable::BaseItemPtr HelpMenu( AudacityProject & )
|
MenuTable::BaseItemPtr HelpMenu( AudacityProject & )
|
||||||
{
|
{
|
||||||
#ifdef __WXMAC__
|
#ifdef __WXMAC__
|
||||||
wxGetApp().s_macHelpMenuTitleName = _("&Help");
|
wxApp::s_macHelpMenuTitleName = _("&Help");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
using namespace MenuTable;
|
using namespace MenuTable;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user