Shortcuts with Cmd leaking through to host OS

Discussions related to using VirtualBox on Mac OS X hosts.
Post Reply
leakycap
Posts: 2
Joined: 6. Aug 2018, 17:50

Shortcuts with Cmd leaking through to host OS

Post by leakycap »

Hi,

I am trying to run Linux in a virtual machine. However, some keybindings that require the mod key (Cmd) are passed through to the host OS, even if the keyboard is supposed to be captured (auto-capture on).

For instance, when I try to close a window in i3 using shift+mod+q, macOS picks it up as the keybinding for logging out, and the window in the virtual machine is not closed.

I am using left Cmd for these bindings, but switched the Host key to right Cmd, to no avail.

I would like the keyboard to stay captured and not leak through to the host OS, unless I press the Host key. What can/must I do?

Thanks! :D

Host OS: macOS 10.13, with extension pack
Guest OS: Manjaro i3, with guest modules
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Shortcuts with Cmd leaking through to host OS

Post by socratis »

There are two shortcuts (key bindings) that will always be captured by the host OSX; Cmd(+Shift)+Q and Cmd(+Shift)+H. Basically what's on the Application menu. They are reserved, and for a good reason. The reservation is done at the Qt level, not sure if VirtualBox can do anything to bypass that.

There was one short period during a beta, where you'd press LeftCmd+Q in an OSX guest, and it actually acted as a Cmd+Q inside the guest! And then you'd press RightCmd+Q (RightCmd being the HostKey) and it would quit the VM! Perfect!

It turned out to be a bug... :(
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
leakycap
Posts: 2
Joined: 6. Aug 2018, 17:50

Re: Shortcuts with Cmd leaking through to host OS

Post by leakycap »

Shame that those are reserved. Guess I'll have to switch mod to Alt, or switch Q and H bindings in particular to use Alt in lieu of Cmd, which I think should be possible(?).

Thanks for your reply and explanation :)
Post Reply