Skip to contentSkip to conversation

Makes -full-screen option work on Mac OS X

PATCH In review Programmingkid 2 participants 2 messages Jan 20, 2015 – Feb 12, 2015

lore
Share & tools
lore
#0 lore raw

PATCH v3 1/1 Makes -full-screen option work on Mac OS X

This patch makes the -full-screen option actually instruct QEMU to enter fullscreen at startup, on Mac OS X.

---
Eliminated compile warning.

 ui/cocoa.m |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
ui/cocoa.m +6 -0
index d37c29b..081d4f2 100644
@@ -1120,6 +1120,12 @@ void cocoa_display_init(DisplayState *ds, int full_screen)
 {
     COCOA_DEBUG("qemu_cocoa: cocoa_display_init\n");
 
+    /* if fullscreen mode is to be used */
+    if (full_screen == true) {
+        [NSApp activateIgnoringOtherApps: YES];
+        [(QemuCocoaAppController *)[[NSApplication sharedApplication] delegate] toggleFullScreen: nil];
+    }
+
     dcl = g_malloc0(sizeof(DisplayChangeListener));
 
     // register vga output callbacks
Signature · 1 line
1.7.5.4