In the init function, set the number of screen modes to zero before they are calculated, as this was causing a problem with the Macintosh version when the game was reset, or a new game was started

git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@363 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
This commit is contained in:
markgrebe 2005-02-18 23:33:32 +00:00
parent 47f8619ec5
commit aba74d2939
1 changed files with 2 additions and 1 deletions

View File

@ -13,7 +13,7 @@
// See the file "license" for information on usage and redistribution of // See the file "license" for information on usage and redistribution of
// this file, and for a DISCLAIMER OF ALL WARRANTIES. // this file, and for a DISCLAIMER OF ALL WARRANTIES.
// //
// $Id: FrameBufferGL.cxx,v 1.11 2005-02-13 19:17:01 stephena Exp $ // $Id: FrameBufferGL.cxx,v 1.12 2005-02-18 23:33:32 markgrebe Exp $
//============================================================================ //============================================================================
#include <SDL.h> #include <SDL.h>
@ -184,6 +184,7 @@ bool FrameBufferGL::init()
} }
// Get the valid OpenGL screenmodes // Get the valid OpenGL screenmodes
myScreenmodeCount = 0;
myScreenmode = SDL_ListModes(NULL, SDL_FULLSCREEN|SDL_OPENGL); myScreenmode = SDL_ListModes(NULL, SDL_FULLSCREEN|SDL_OPENGL);
if((myScreenmode != (SDL_Rect**) -1) && (myScreenmode != (SDL_Rect**) 0)) if((myScreenmode != (SDL_Rect**) -1) && (myScreenmode != (SDL_Rect**) 0))
for(uInt32 i = 0; myScreenmode[i]; ++i) for(uInt32 i = 0; myScreenmode[i]; ++i)