changeset 4016:3f93ccc2c01e SDL-1.2

Clear the NOFRAME and RESIZABLE flags in the X11 target before setting their new values, so multiple calls to SetVideoMode() that toggle these will end up with the right data. Fixes Bugzilla #441.
author Ryan C. Gordon <icculus@icculus.org>
date Sun, 08 Jul 2007 01:50:26 +0000
parents 7e878cc4250a
children 9a451f59b388
files src/video/x11/SDL_x11video.c
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/video/x11/SDL_x11video.c	Sun Jul 08 01:36:16 2007 +0000
+++ b/src/video/x11/SDL_x11video.c	Sun Jul 08 01:50:26 2007 +0000
@@ -1203,6 +1203,9 @@
 		current->pitch = SDL_CalculatePitch(current);
 		X11_ResizeImage(this, current, flags);
 	}
+
+	/* Clear these flags and set them only if they are in the new set. */
+	current->flags &= ~(SDL_RESIZABLE|SDL_NOFRAME);
 	current->flags |= (flags&(SDL_RESIZABLE|SDL_NOFRAME));
 
   done: