Skip to content

Commit

Permalink
Fixed a compiler warning when building with Mac OS X target < 10.7.
Browse files Browse the repository at this point in the history
  • Loading branch information
icculus committed Nov 4, 2011
1 parent c36e553 commit 5fb1ebd
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions src/video/quartz/SDL_QuartzVideo.m
Expand Up @@ -798,9 +798,6 @@ other blitting while waiting on the VBL (and hence results in higher framerates)
/* Setup OpenGL for a fullscreen context */
if (flags & SDL_OPENGL) {

CGLError err;
CGLContextObj ctx;

if ( ! QZ_SetupOpenGL (this, bpp, flags) ) {
goto ERR_NO_GL;
}
Expand All @@ -818,13 +815,18 @@ other blitting while waiting on the VBL (and hence results in higher framerates)
/* Apparently Lion checks some version flag set by the linker
and changes API behavior. Annoying. */
#if (MAC_OS_X_VERSION_MAX_ALLOWED < 1070)
[ qz_window setLevel:NSNormalWindowLevel ];
ctx = QZ_GetCGLContextObj (gl_context);
err = CGLSetFullScreen (ctx);
{
CGLError err;
CGLContextObj ctx;

[ qz_window setLevel:NSNormalWindowLevel ];
ctx = QZ_GetCGLContextObj (gl_context);
err = CGLSetFullScreen (ctx);

if (err) {
SDL_SetError ("Error setting OpenGL fullscreen: %s", CGLErrorString(err));
goto ERR_NO_GL;
if (err) {
SDL_SetError ("Error setting OpenGL fullscreen: %s", CGLErrorString(err));
goto ERR_NO_GL;
}
}
#else
[ qz_window setLevel:CGShieldingWindowLevel() ];
Expand Down

0 comments on commit 5fb1ebd

Please sign in to comment.