Fixed a compiler warning when building with Mac OS X target < 10.7.
--HG-- branch : SDL-1.2
This commit is contained in:
parent
e51cfbcb74
commit
489665a4cb
1 changed files with 11 additions and 9 deletions
|
@ -798,9 +798,6 @@ static SDL_Surface* QZ_SetVideoFullScreen (_THIS, SDL_Surface *current, int widt
|
||||||
/* Setup OpenGL for a fullscreen context */
|
/* Setup OpenGL for a fullscreen context */
|
||||||
if (flags & SDL_OPENGL) {
|
if (flags & SDL_OPENGL) {
|
||||||
|
|
||||||
CGLError err;
|
|
||||||
CGLContextObj ctx;
|
|
||||||
|
|
||||||
if ( ! QZ_SetupOpenGL (this, bpp, flags) ) {
|
if ( ! QZ_SetupOpenGL (this, bpp, flags) ) {
|
||||||
goto ERR_NO_GL;
|
goto ERR_NO_GL;
|
||||||
}
|
}
|
||||||
|
@ -818,13 +815,18 @@ static SDL_Surface* QZ_SetVideoFullScreen (_THIS, SDL_Surface *current, int widt
|
||||||
/* Apparently Lion checks some version flag set by the linker
|
/* Apparently Lion checks some version flag set by the linker
|
||||||
and changes API behavior. Annoying. */
|
and changes API behavior. Annoying. */
|
||||||
#if (MAC_OS_X_VERSION_MAX_ALLOWED < 1070)
|
#if (MAC_OS_X_VERSION_MAX_ALLOWED < 1070)
|
||||||
[ qz_window setLevel:NSNormalWindowLevel ];
|
{
|
||||||
ctx = QZ_GetCGLContextObj (gl_context);
|
CGLError err;
|
||||||
err = CGLSetFullScreen (ctx);
|
CGLContextObj ctx;
|
||||||
|
|
||||||
|
[ qz_window setLevel:NSNormalWindowLevel ];
|
||||||
|
ctx = QZ_GetCGLContextObj (gl_context);
|
||||||
|
err = CGLSetFullScreen (ctx);
|
||||||
|
|
||||||
if (err) {
|
if (err) {
|
||||||
SDL_SetError ("Error setting OpenGL fullscreen: %s", CGLErrorString(err));
|
SDL_SetError ("Error setting OpenGL fullscreen: %s", CGLErrorString(err));
|
||||||
goto ERR_NO_GL;
|
goto ERR_NO_GL;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
[ qz_window setLevel:CGShieldingWindowLevel() ];
|
[ qz_window setLevel:CGShieldingWindowLevel() ];
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue