[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 1/2] ui/cocoa: capture all keys and combos when mouse is grab
From: |
'Gerd Hoffmann ' |
Subject: |
Re: [PATCH 1/2] ui/cocoa: capture all keys and combos when mouse is grabbed |
Date: |
Fri, 30 Apr 2021 10:05:50 +0200 |
On Thu, Apr 29, 2021 at 08:47:04PM -0300, gustavo@noronha.eti.br wrote:
> From: Gustavo Noronha Silva <gustavo@noronha.eti.br>
>
> Applications such as Gnome may use Alt-Tab and Super-Tab for different
> purposes, some use Ctrl-arrows so we want to allow qemu to handle
> everything when it captures the mouse/keyboard.
>
> However, Mac OS handles some combos like Command-Tab and Ctrl-arrows
> at an earlier part of the event handling chain, not letting qemu see it.
>
> We add a global Event Tap that allows qemu to see all events when the
> mouse is grabbed. Note that this requires additional permissions.
>
> See:
>
> https://developer.apple.com/documentation/coregraphics/1454426-cgeventtapcreate?language=objc#discussion
> https://support.apple.com/en-in/guide/mac-help/mh32356/mac
Looks all sensible to me, I'd like to have the opinion from the MacOS
experts for this one though.
thanks,
Gerd
[PATCH 2/2] ui/cocoa: add option to swap Option and Command, enable by default, gustavo, 2021/04/29