changeset 5272:93ea62a5ba8f

Only expose the OpenGL flag to SDL 1.2 if it was requested. The window flags mean the window is OpenGL capable. The surface flag means that the surface is a stub surface representing a window that has an OpenGL context attached.
author Sam Lantinga <slouken@libsdl.org>
date Sat, 12 Feb 2011 08:17:37 -0800
parents e107518710f6
children c5a04f3c3908
files src/SDL_compat.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/SDL_compat.c	Sat Feb 12 07:57:35 2011 -0800
+++ b/src/SDL_compat.c	Sat Feb 12 08:17:37 2011 -0800
@@ -519,7 +519,7 @@
     if (window_flags & SDL_WINDOW_FULLSCREEN) {
         surface_flags |= SDL_FULLSCREEN;
     }
-    if (window_flags & SDL_WINDOW_OPENGL) {
+    if ((window_flags & SDL_WINDOW_OPENGL) && (flags & SDL_OPENGL)) {
         surface_flags |= SDL_OPENGL;
     }
     if (window_flags & SDL_WINDOW_RESIZABLE) {