Fix a game mode crashing bug, conditional compilation for Windows, and comment out some diagnostic prints (John Fay)
git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@511 7f0cb862-5218-0410-a997-914c9d46530a
This commit is contained in:
parent
34d1c10c25
commit
7e23a609ff
@ -549,6 +549,8 @@ void FGAPIENTRY glutLeaveGameMode( void )
|
|||||||
|
|
||||||
fgAddToWindowDestroyList( fgStructure.GameMode );
|
fgAddToWindowDestroyList( fgStructure.GameMode );
|
||||||
|
|
||||||
|
fgStructure.GameMode = NULL ;
|
||||||
|
|
||||||
#if TARGET_HOST_UNIX_X11
|
#if TARGET_HOST_UNIX_X11
|
||||||
|
|
||||||
XUngrabPointer( fgDisplay.Display, CurrentTime );
|
XUngrabPointer( fgDisplay.Display, CurrentTime );
|
||||||
|
@ -191,7 +191,7 @@ struct tagSFG_XYUse
|
|||||||
typedef struct tagSFG_Time SFG_Time;
|
typedef struct tagSFG_Time SFG_Time;
|
||||||
struct tagSFG_Time
|
struct tagSFG_Time
|
||||||
{
|
{
|
||||||
#ifdef WIN32
|
#if TARGET_HOST_WIN32 || TARGET_HOST_WINCE
|
||||||
DWORD Value;
|
DWORD Value;
|
||||||
#else
|
#else
|
||||||
struct timeval Value;
|
struct timeval Value;
|
||||||
|
@ -1321,7 +1321,7 @@ LRESULT CALLBACK fgWindowProc( HWND hWnd, UINT uMsg, WPARAM wParam,
|
|||||||
break;
|
break;
|
||||||
#if 0
|
#if 0
|
||||||
case WM_SETFOCUS:
|
case WM_SETFOCUS:
|
||||||
printf("WM_SETFOCUS: %p\n", window );
|
/* printf("WM_SETFOCUS: %p\n", window ); */
|
||||||
lRet = DefWindowProc( hWnd, uMsg, wParam, lParam );
|
lRet = DefWindowProc( hWnd, uMsg, wParam, lParam );
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -1329,8 +1329,8 @@ LRESULT CALLBACK fgWindowProc( HWND hWnd, UINT uMsg, WPARAM wParam,
|
|||||||
if (LOWORD(wParam) != WA_INACTIVE)
|
if (LOWORD(wParam) != WA_INACTIVE)
|
||||||
{
|
{
|
||||||
/* glutSetCursor( fgStructure.Window->State.Cursor ); */
|
/* glutSetCursor( fgStructure.Window->State.Cursor ); */
|
||||||
printf("WM_ACTIVATE: glutSetCursor( %p, %d)\n", window,
|
/* printf("WM_ACTIVATE: glutSetCursor( %p, %d)\n", window,
|
||||||
window->State.Cursor );
|
window->State.Cursor ); */
|
||||||
glutSetCursor( window->State.Cursor );
|
glutSetCursor( window->State.Cursor );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user