Have wxWidgets install signal handlers to catch crashes

and disconnect any wiimotes.

The Windows code has special handling of both exceptions
and bluetooth connection state, neither of which I really
understand, so this is enabled on the other platforms only.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6821 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Soren Jorvang 2011-01-12 01:27:01 +00:00
parent 78ec771063
commit 22d66f51a8
2 changed files with 8 additions and 0 deletions

View File

@ -175,6 +175,8 @@ bool DolphinApp::OnInit()
#ifdef _WIN32
EXTENDEDTRACEINITIALIZE(".");
SetUnhandledExceptionFilter(&MyUnhandledExceptionFilter);
#else
wxHandleFatalExceptions(true);
#endif
// TODO: if First Boot
@ -423,6 +425,11 @@ int DolphinApp::OnExit()
return wxApp::OnExit();
}
void DolphinApp::OnFatalException()
{
WiimoteReal::Shutdown();
}
// ------------
// Talk to GUI

View File

@ -28,6 +28,7 @@ public:
bool OnInit();
void OnEndSession();
int OnExit();
void OnFatalException();
CFrame* GetCFrame();
void InitLanguageSupport();