diff options
author | Vladimir Chtchetkine <vchtchetkine@google.com> | 2011-01-12 14:38:19 -0800 |
---|---|---|
committer | Vladimir Chtchetkine <vchtchetkine@google.com> | 2011-01-13 08:30:30 -0800 |
commit | cf755ea6f4b850a6afd12ef8308da8def7ba8941 (patch) | |
tree | e67ff4e0ba37812ef4fae43e39f99a64b0802c45 /vl-android.c | |
parent | aedf1d5c1c7f5386b3e01c74853a9928bd73daa8 (diff) | |
download | external_qemu-cf755ea6f4b850a6afd12ef8308da8def7ba8941.zip external_qemu-cf755ea6f4b850a6afd12ef8308da8def7ba8941.tar.gz external_qemu-cf755ea6f4b850a6afd12ef8308da8def7ba8941.tar.bz2 |
Hook up framebuffer changes with UI window
Change-Id: Ib2dff72c808614cd6ded096d62717afc1c41e667
Diffstat (limited to 'vl-android.c')
-rw-r--r-- | vl-android.c | 31 |
1 files changed, 14 insertions, 17 deletions
diff --git a/vl-android.c b/vl-android.c index d89a7e5..444461b 100644 --- a/vl-android.c +++ b/vl-android.c @@ -4587,6 +4587,17 @@ int main(int argc, char **argv, char **envp) } } + /* Parse GUI option early, so when we init framebuffer in goldfish we have + * saved display parameters. */ + if (android_op_gui) { + if (parse_androig_gui_option(android_op_gui, + &android_display_width, + &android_display_height, + &android_display_bpp)) { + PANIC("Unable to parse -android-gui parameter: %s", android_op_gui); + } + } + /* Initialize character map. */ if (android_charmap_setup(op_charmap_file)) { if (op_charmap_file) { @@ -5164,16 +5175,12 @@ int main(int argc, char **argv, char **envp) } } + /* just use the first displaystate for the moment */ + ds = display_state = get_displaystate(); + if (!display_state) { if (android_op_gui) { /* Initialize display from the command line parameters. */ - if (parse_androig_gui_option(android_op_gui, - &android_display_width, - &android_display_height, - &android_display_bpp)) { - PANIC("Unable to parse -android-gui parameter: %s", - android_op_gui); - } android_display_init_from(android_display_width, android_display_height, 0, android_display_bpp); @@ -5182,21 +5189,11 @@ int main(int argc, char **argv, char **envp) } } else if (android_op_gui) { /* Resize display from the command line parameters. */ - if (parse_androig_gui_option(android_op_gui, - &android_display_width, - &android_display_height, - &android_display_bpp)) { - PANIC("Unable to parse -android-gui parameter: %s", - android_op_gui); - } display_state->surface = qemu_resize_displaysurface(display_state, android_display_width, android_display_height); } - /* just use the first displaystate for the moment */ - ds = display_state = get_displaystate(); - if (display_type == DT_DEFAULT) { #if defined(CONFIG_SDL) || defined(CONFIG_COCOA) display_type = DT_SDL; |