Call SetErrorMode() for all Windows applications, not just wxMSW ones.
This suppresses default system error message boxes when trying to load an invalid DLL in wxGTK/Windows. Closes #15559. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74974 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
fda2a17812
commit
0180c58801
@ -173,6 +173,10 @@ wxAppConsoleBase::~wxAppConsoleBase()
|
||||
|
||||
bool wxAppConsoleBase::Initialize(int& WXUNUSED(argc), wxChar **WXUNUSED(argv))
|
||||
{
|
||||
#if defined(__WINDOWS__) && !defined(__WXWINCE__)
|
||||
SetErrorMode(SEM_FAILCRITICALERRORS|SEM_NOOPENFILEERRORBOX);
|
||||
#endif
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -646,12 +646,6 @@ bool wxApp::Initialize(int& argc, wxChar **argv)
|
||||
SHInitExtraControls();
|
||||
#endif
|
||||
|
||||
#ifndef __WXWINCE__
|
||||
// Don't show a message box if a function such as SHGetFileInfo
|
||||
// fails to find a device.
|
||||
SetErrorMode(SEM_FAILCRITICALERRORS|SEM_NOOPENFILEERRORBOX);
|
||||
#endif
|
||||
|
||||
wxOleInitialize();
|
||||
|
||||
#if !defined(__WXMICROWIN__) && !defined(__WXWINCE__)
|
||||
|
Loading…
Reference in New Issue
Block a user