Moving the Windows-specific "glutInitWithExit" function to a Windows-specific file

git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@1016 7f0cb862-5218-0410-a997-914c9d46530a
This commit is contained in:
fayjf 2012-01-29 03:25:31 +00:00
parent d59e23ba2e
commit 1c8c92fa89
2 changed files with 11 additions and 10 deletions

View File

@ -648,16 +648,6 @@ void FGAPIENTRY glutInit( int* pargc, char** argv )
}
}
#if TARGET_HOST_MS_WINDOWS
void (__cdecl *__glutExitFunc)( int return_value ) = NULL;
void FGAPIENTRY __glutInitWithExit( int *pargc, char **argv, void (__cdecl *exit_function)(int) )
{
__glutExitFunc = exit_function;
glutInit(pargc, argv);
}
#endif
/*
* Undoes all the "glutInit" stuff
*/

View File

@ -329,3 +329,14 @@ int XParseGeometry (
/* -- PLATFORM-SPECIFIC INTERFACE FUNCTION -------------------------------------------------- */
void (__cdecl *__glutExitFunc)( int return_value ) = NULL;
void FGAPIENTRY __glutInitWithExit( int *pargc, char **argv, void (__cdecl *exit_function)(int) )
{
__glutExitFunc = exit_function;
glutInit(pargc, argv);
}