Send control-alt key combinations to the guest if not used by the user 
interface.

Signed-off-by: John Arbuckle <programmingk...@gmail.com>
---
 ui/cocoa.m | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/ui/cocoa.m b/ui/cocoa.m
index d3e7907103..6920ea38aa 100644
--- a/ui/cocoa.m
+++ b/ui/cocoa.m
@@ -634,6 +634,14 @@ - (void) handleEvent:(NSEvent *)event
                     case Q_KEY_CODE_G:
                         [self ungrabMouse];
                         break;
+
+                    // send to the guest
+                    default:
+                        if (qemu_console_is_graphic(NULL)) {
+                            qemu_input_event_send_key_qcode(dcl->con, keycode,
+                                                            true);
+                        }
+                    break;
                 }
 
             // handle keys for graphic console
-- 
2.11.0 (Apple Git-81)


Reply via email to