VirtualBox

Opened 17 years ago

Closed 8 years ago

#1066 closed enhancement (obsolete)

Improved automatic keyboard and mouse capture

Reported by: Brandon Owned by:
Component: GUI Version: VirtualBox 1.5.4
Keywords: Cc:
Guest type: other Host type: other

Description (last modified by aeichner)

Currently, vbox captures the keyboard when a vbox guest window is active and ignores the keyboard when a vbox guest is not the active window. VMWare automatically captures the keyboard when the mouse enters the guest display area regardless of whether the window is active or not and releases it when the mouse leaves the guest display area. The VMWare behavior allows for better integration of the virtual machine into the host environment and would be nice to have in vbox.

It would also be nice to capture all keyboard input when the guest has captured the keyboard so that special combinations, such as Ctrl+Alt+F1, don't need a special host key combination to work. This is especially important in fullscreen mode where only the host+Home or host+F combination should be passed to the host (IMHO).

Change History (5)

comment:1 by Michael Thayer, 17 years ago

Regarding the first point - I hate to give such a boring answer, but actually what VMWare does is to force focus-follows-mouse on the user. At least in Linux/X11, this is something which the window manager/desktop environment is in charge of, and you can configure it there. It is considered "bad behaviour" when an application tries to override the window manager on this sort of thing, and might make other people unhappy.

Regarding the second, I didn't know that it was possible for applications to capture Ctrl-Alt-F1 under X.Org if the window system is using them. Does VMWare really succeed in doing this?

in reply to:  1 comment:2 by Brandon, 17 years ago

Replying to michael:

Regarding the second, I didn't know that it was possible for applications to capture Ctrl-Alt-F1 under X.Org if the window system is using them. Does VMWare really succeed in doing this?

I'm fairly certain that in fullscreen mode VMWare captures almost all keystrokes, including Ctrl+Alt+<key>. I will have to fire up VMWare and check. It's been sitting dormant since I started using VirtualBox because I've been so impressed with vbox.

in reply to:  1 comment:3 by Brandon, 17 years ago

Replying to michael:

I just fired up my Windows XP and Feisty VMWare guests to verify my statements.

Regarding the first point - I hate to give such a boring answer, but actually what VMWare does is to force focus-follows-mouse on the user.

This doesn't appear to be the case. With focus-follows-mouse, the window is activated and brought to the top when the mouse cursor enters the window and focus is lost when the cursor leaves the window. With VMWare, the keyboard and mouse are not captured when the cursor enters the VMWare window, but when the cursor enters the guest area within the VMWare window (without activating the VMWare window). So if I have Firefox open over VMWare and I move the mouse cursor over the VMWare toolbar and press Alt+2, the tabs are switched in Firefox, not in VMWare. Then if I move the cursor over the guest area in the VMWare window and press a key, it is sent to the guest. All of this is done without changing the active window. This issue, however, isn't that important.

Regarding the second, I didn't know that it was possible for applications to capture Ctrl-Alt-F1 under X.Org if the window system is using them. Does VMWare really succeed in doing this?

VMWare DOES capture all key combinations. I am able to switch between virtual terminals in my Feisty VM using Ctrl+Alt+<Fn> keys and Ctrl+Alt+Backspace restarts X on the guest. Ctrl+Alt+Delete in the Windows XP guest brings up the task manager. This works in both fullscreen and windowed mode. I'm not sure how they are accomplishing this, but every key combination gets captured when the mouse cursor is over the guest area. Could it be that they are using a loadable kernel module to capture these combinations?

comment:4 by Frank Mehnert, 16 years ago

Component: otherGUI

comment:5 by aeichner, 8 years ago

Description: modified (diff)
Resolution: obsolete
Status: newclosed

Please reopen if still relevant with a recent VirtualBox release.

Note: See TracTickets for help on using tickets.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette