X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?a=blobdiff_plain;f=src%2FCommon%2Ffreeglut_menu.c;h=2fc528be19f428f9d1571893b37cd2c5082d47d1;hb=814beaa77f437cf4cf6cac9f748235488f6478a1;hp=91b2b832d84b0a00da312b66ba548b222ad1554a;hpb=9276442d096db4de1ba112672f80dbb822fbb3df;p=freeglut diff --git a/src/Common/freeglut_menu.c b/src/Common/freeglut_menu.c index 91b2b83..2fc528b 100644 --- a/src/Common/freeglut_menu.c +++ b/src/Common/freeglut_menu.c @@ -85,7 +85,7 @@ static float menu_pen_hback [4] = {1.0f, 1.0f, 1.0f, 1.0f}; #endif -extern GLvoid fghGetGameModeVMaxExtent( SFG_Window* window, int* x, int* y ); +extern GLvoid fgPlatformGetGameModeVMaxExtent( SFG_Window* window, int* x, int* y ); /* -- PRIVATE FUNCTIONS ---------------------------------------------------- */ @@ -143,15 +143,15 @@ static void fghDeactivateSubMenu( SFG_MenuEntry *menuEntry ) * Private function to get the virtual maximum screen extent */ #if TARGET_HOST_POSIX_X11 -static GLvoid fghGetGameModeVMaxExtent( SFG_Window* window, int* x, int* y ) +GLvoid fgPlatformGetGameModeVMaxExtent( SFG_Window* window, int* x, int* y ) { int wx, wy; Window w; XTranslateCoordinates( - fgDisplay.Display, + fgDisplay.pDisplay.Display, window->Window.Handle, - fgDisplay.RootWindow, + fgDisplay.pDisplay.RootWindow, 0, 0, &wx, &wy, &w); *x = fgState.GameModeSize.X + wx; @@ -163,7 +163,7 @@ static GLvoid fghGetGameModeVMaxExtent( SFG_Window* window, int* x, int* y ) static GLvoid fghGetVMaxExtent( SFG_Window* window, int* x, int* y ) { if( fgStructure.GameModeWindow ) - fghGetGameModeVMaxExtent ( window, x, y ); + fgPlatformGetGameModeVMaxExtent ( window, x, y ); else { *x = fgDisplay.ScreenWidth; @@ -783,14 +783,6 @@ int FGAPIENTRY glutCreateMenu( void(* callback)( int ) ) return fgCreateMenu( callback )->ID; } -#if TARGET_HOST_MS_WINDOWS -int FGAPIENTRY __glutCreateMenuWithExit( void(* callback)( int ), void (__cdecl *exit_function)(int) ) -{ - __glutExitFunc = exit_function; - return glutCreateMenu( callback ); -} -#endif - /* * Destroys a menu object, removing all references to it */