1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-05-03 17:19:43 +02:00

Bug1561: delay the recovery dialog until after application init

This commit is contained in:
Paul Licameli 2016-12-19 17:56:52 -05:00
parent f4a5805ae6
commit 426cb9c40c

View File

@ -1367,7 +1367,7 @@ bool AudacityApp::OnInit()
// Parse command line and handle options that might require
// immediate exit...no need to initialize all of the audio
// stuff to display the version string.
auto parser = ParseCommandLine();
std::shared_ptr< wxCmdLineParser > parser{ ParseCommandLine().release() };
if (!parser)
{
// Either user requested help or a parsing error occured
@ -1506,6 +1506,8 @@ bool AudacityApp::OnInit()
Importer::Get().Initialize();
// Bug1561: delay the recovery dialog, to avoid crashes.
CallAfter( [=] () mutable {
//
// Auto-recovery
//
@ -1529,8 +1531,8 @@ bool AudacityApp::OnInit()
return false;
}
// As of wx3, there's no need to process the filename arguments as they
// will be sent view the MacOpenFile() method.
// As of wx3, there's no need to process the filename arguments as they
// will be sent view the MacOpenFile() method.
#if !defined(__WXMAC__)
for (size_t i = 0, cnt = parser->GetParamCount(); i < cnt; i++)
{
@ -1538,6 +1540,7 @@ bool AudacityApp::OnInit()
}
#endif
}
} );
gInited = true;