X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?a=blobdiff_plain;f=src%2Fmswin%2Ffreeglut_menu_mswin.c;h=e280624f57d7bc1f41c57d5befe94162e59d642f;hb=ef90e5c72102f31823452430eb0b704dd3a44113;hp=3def1b9cb260c2fb810581b9f9411b2dbf6944ce;hpb=625d4f9446481f4a1684314cb559df7976090578;p=freeglut diff --git a/src/mswin/freeglut_menu_mswin.c b/src/mswin/freeglut_menu_mswin.c index 3def1b9..e280624 100644 --- a/src/mswin/freeglut_menu_mswin.c +++ b/src/mswin/freeglut_menu_mswin.c @@ -25,6 +25,7 @@ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +#define FREEGLUT_BUILDING_LIB #include #include "../Common/freeglut_internal.h" @@ -34,3 +35,14 @@ GLvoid fgPlatformGetGameModeVMaxExtent( SFG_Window* window, int* x, int* y ) *x = glutGet ( GLUT_SCREEN_WIDTH ); *y = glutGet ( GLUT_SCREEN_HEIGHT ); } + + + +/* -- PLATFORM-SPECIFIC INTERFACE FUNCTION -------------------------------------------------- */ + +int FGAPIENTRY __glutCreateMenuWithExit( void(* callback)( int ), void (__cdecl *exit_function)(int) ) +{ + __glutExitFunc = exit_function; + return glutCreateMenu( callback ); +} +