Leave game mode on "deinitialization" if we entered it, per e-mail from John Tsiombik...
authorJohn F. Fay <johnffay@nettally.com>
Tue, 20 Dec 2011 03:21:25 +0000 (03:21 +0000)
committerJohn F. Fay <johnffay@nettally.com>
Tue, 20 Dec 2011 03:21:25 +0000 (03:21 +0000)
git-svn-id: svn+ssh://svn.code.sf.net/p/freeglut/code/trunk/freeglut/freeglut@960 7f0cb862-5218-0410-a997-914c9d46530a

src/freeglut_init.c

index 8c254bc..f59a456 100644 (file)
@@ -413,6 +413,11 @@ void fgDeinitialize( void )
         return;
     }
 
+       /* If we're in game mode, we want to leave game mode */
+    if( fgStructure.GameModeWindow ) {
+        glutLeaveGameMode();
+    }
+
     /* If there was a menu created, destroy the rendering context */
     if( fgStructure.MenuContext )
     {