]> www.infradead.org Git - users/dwmw2/qemu.git/commitdiff
ui/cocoa.m: Send ctrl-alt key combos to guest if QEMU isn't using them
authorPeter Maydell <peter.maydell@linaro.org>
Tue, 7 Nov 2017 10:14:14 +0000 (10:14 +0000)
committerPeter Maydell <peter.maydell@linaro.org>
Tue, 7 Nov 2017 10:14:14 +0000 (10:14 +0000)
Send those ctrl-alt key combos that QEMU doesn't treat specially to
the guest rather than ignoring them.

All the case where we do special handling of ctrl-alt-X exit the
event handling using a "return" statement, so we can simply allow
the rest to fall through into the normal key handling by deleting
the now-spurious "else".

We take the opportunity to clean up some oddly-formatted and
now rather uninformative comments by removing them.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
ui/cocoa.m

index f39c792cba09bce85159a038a76ae89029a89786..330ccebf90d0465561db6f590d6d85b0665fc23a 100644 (file)
@@ -704,12 +704,10 @@ QemuCocoaView *cocoaView;
                             return;
                     }
                 }
+            }
 
-            // handle keys for graphic console
-            } else if (qemu_console_is_graphic(NULL)) {
+            if (qemu_console_is_graphic(NULL)) {
                 qemu_input_event_send_key_qcode(dcl->con, keycode, true);
-
-            // handlekeys for Monitor
             } else {
                 [self handleMonitorInput: event];
             }