qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH 2/2] ui/cocoa.m: send ctrl-alt key combinations to guest if not used by QEMU
@ 2017-08-21 20:52 John Arbuckle
  2017-08-21 20:52 ` [Qemu-devel] [PATCH 0/2] ui/cocoa.m: enable guest to see control-alt key combinations John Arbuckle
  2017-08-21 20:52 ` [Qemu-devel] [PATCH 1/2] ui/cocoa.m: move ungrab to ctrl-alt-g John Arbuckle
  0 siblings, 2 replies; 3+ messages in thread
From: John Arbuckle @ 2017-08-21 20:52 UTC (permalink / raw)
  To: qemu-devel@nongnu.org qemu-devel peter . maydell @ linaro . org
  Cc: John Arbuckle

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

Signed-off-by: John Arbuckle <programmingkidx@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)

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-08-21 20:52 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-08-21 20:52 [Qemu-devel] [PATCH 2/2] ui/cocoa.m: send ctrl-alt key combinations to guest if not used by QEMU John Arbuckle
2017-08-21 20:52 ` [Qemu-devel] [PATCH 0/2] ui/cocoa.m: enable guest to see control-alt key combinations John Arbuckle
2017-08-21 20:52 ` [Qemu-devel] [PATCH 1/2] ui/cocoa.m: move ungrab to ctrl-alt-g John Arbuckle

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).