Patchwork [02/15] sdl: Do not make full screen mode resizable

login
register
mail settings
Submitter Jan Kiszka
Date July 30, 2011, 9:39 a.m.
Message ID <6472425a5f71ba9635f6bac1c3522f8920910778.1312018756.git.jan.kiszka@web.de>
Download mbox | patch
Permalink /patch/107489/
State New
Headers show

Comments

Jan Kiszka - July 30, 2011, 9:39 a.m.
From: Jan Kiszka <jan.kiszka@siemens.com>

This prevents continuous resizing events and improper screen setups when
going full screen.

CC: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
 ui/sdl.c |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

Patch

diff --git a/ui/sdl.c b/ui/sdl.c
index 9efcda5..9a92b47 100644
--- a/ui/sdl.c
+++ b/ui/sdl.c
@@ -97,9 +97,12 @@  static void do_sdl_resize(int new_width, int new_height, int bpp)
 
     //    printf("resizing to %d %d\n", w, h);
 
-    flags = SDL_HWSURFACE|SDL_ASYNCBLIT|SDL_HWACCEL|SDL_RESIZABLE;
-    if (gui_fullscreen)
+    flags = SDL_HWSURFACE | SDL_ASYNCBLIT | SDL_HWACCEL;
+    if (gui_fullscreen) {
         flags |= SDL_FULLSCREEN;
+    } else {
+        flags |= SDL_RESIZABLE;
+    }
     if (gui_noframe)
         flags |= SDL_NOFRAME;