Files
itgmania212121/stepmania/src/arch/ArchHooks/ArchHooks_Unix.cpp
T

36 lines
826 B
C++
Raw Normal View History

2003-07-24 08:19:20 +00:00
#include "global.h"
#include "ArchHooks_Unix.h"
#include "archutils/Unix/SignalHandler.h"
#if defined(CRASH_HANDLER)
2003-07-24 08:19:20 +00:00
#include "archutils/Unix/CrashHandler.h"
#endif
#include "SDL_utils.h"
static void EmergencyShutdown( int signal )
{
/* If we don't actually use SDL for video, this should be a no-op. */
if( SDL_WasInit(SDL_INIT_VIDEO) )
SDL_QuitSubSystem(SDL_INIT_VIDEO);
}
2003-07-24 08:19:20 +00:00
ArchHooks_Unix::ArchHooks_Unix()
{
#if defined(CRASH_HANDLER)
2003-07-24 08:19:20 +00:00
CrashHandlerHandleArgs();
SignalHandler::OnClose( CrashSignalHandler );
#endif
/* Set up EmergencyShutdown, to try to shut down the window if we crash.
* This might blow up, so be sure to do it after the crash handler. */
SignalHandler::OnClose( EmergencyShutdown );
2003-07-24 08:19:20 +00:00
}
/*
* Copyright (c) 2003 by the person(s) listed below. All rights reserved.
*
* Glenn Maynard
*/