Clear the NOFRAME and RESIZABLE flags in the X11 target before setting their SDL-1.2
authorRyan C. Gordon
Sun, 08 Jul 2007 01:50:26 +0000
branchSDL-1.2
changeset 40163f93ccc2c01e
parent 4015 7e878cc4250a
child 4017 9a451f59b388
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.
src/video/x11/SDL_x11video.c
     1.1 --- a/src/video/x11/SDL_x11video.c	Sun Jul 08 01:36:16 2007 +0000
     1.2 +++ b/src/video/x11/SDL_x11video.c	Sun Jul 08 01:50:26 2007 +0000
     1.3 @@ -1203,6 +1203,9 @@
     1.4  		current->pitch = SDL_CalculatePitch(current);
     1.5  		X11_ResizeImage(this, current, flags);
     1.6  	}
     1.7 +
     1.8 +	/* Clear these flags and set them only if they are in the new set. */
     1.9 +	current->flags &= ~(SDL_RESIZABLE|SDL_NOFRAME);
    1.10  	current->flags |= (flags&(SDL_RESIZABLE|SDL_NOFRAME));
    1.11  
    1.12    done: