aboutsummaryrefslogtreecommitdiff
path: root/ui
diff options
context:
space:
mode:
authorJan Kiszka <jan.kiszka@siemens.com>2011-07-30 11:39:11 +0200
committerAnthony Liguori <aliguori@us.ibm.com>2011-08-05 10:57:35 -0500
commit110defd753906a01d01d0cabfb2d8db77b3271ef (patch)
tree79062d6532d4226a87c0c596273545974ac4771d /ui
parent982aae66ff75dced49990d7cce8dc0be31aff7e1 (diff)
sdl: Initialize gui_fullscreen earlier during setup
This ensures that we actually enter full screen on startup when e.g. '-vga none -full-screen' was specified. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'ui')
-rw-r--r--ui/sdl.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/ui/sdl.c b/ui/sdl.c
index 80bf776104..f19bae2b27 100644
--- a/ui/sdl.c
+++ b/ui/sdl.c
@@ -891,6 +891,11 @@ void sdl_display_init(DisplayState *ds, int full_screen, int no_frame)
qemu_free(filename);
}
+ if (full_screen) {
+ gui_fullscreen = 1;
+ sdl_grab_start();
+ }
+
dcl = qemu_mallocz(sizeof(DisplayChangeListener));
dcl->dpy_update = sdl_update;
dcl->dpy_resize = sdl_resize;
@@ -920,8 +925,4 @@ void sdl_display_init(DisplayState *ds, int full_screen, int no_frame)
sdl_cursor_normal = SDL_GetCursor();
atexit(sdl_cleanup);
- if (full_screen) {
- gui_fullscreen = 1;
- sdl_grab_start();
- }
}