0

I installed Ubuntu under virtualbox under OS X IN MacBook Pro.

A while ago, I asked a question about how to switch between windows in the guest Ubuntu by keystrokes, and the reply at https://apple.stackexchange.com/a/241981/12994 suggested to press the left command key once before pressing alt-tab.

It sometimes works, but sometimes immediately following pressing the left command key, Virtualbox will pop up a window saying:

You have clicked the mouse inside the Virtual Machine display or pressed the host key. This will cause the Virtual Machine to capture the host mouse pointer (only if the mouse pointer integration is not currently supported by the guest OS) and the keyboard, which will make them unavailable to other applications running on your host machine. You can press the host key at any time to uncapture the keyboard and mouse (if it is captured) and return them to normal operation. The currently assigned host key is shown on the status bar at the bottom of the Virtual Machine window, next to the  icon. This icon, together with the mouse icon placed nearby, indicate the current keyboard and mouse capture state. The host key is currently defined as Left ⌘.

and asks me whether to choose cancel or capture.

Why does it sometimes work and sometimes brings out the interrupting Virtualbox window? How shall I switch between windows in the guest Ubuntu?

Thanks.

1 Answer 1

1

It's because your mouse and keyboard is captured by the VM instance.

When you mouse is captured in the VM window, pressing the Left ⌘ Cmd will bring up the window you described. When it's not captured, it won't.

If you want to avoid this problem, instal the Guest Additions.

3
  • Thanks I think I have installed the guest additions already. I am confused why sometimes pressing left-command key will bring out the virtualbox window and sometimes don't, and how I can make it work always.
    – Tim
    Commented Jun 20, 2016 at 19:58
  • It depends on if the mouse and/or keyboard is captured. If it's not captured, it won't bring up the window. If you have GA installed, you shouldn't have this problem.
    – Allan
    Commented Jun 20, 2016 at 20:06
  • Yes, I think I should click Capture, and then I don't need to click the left command key any more as long as I stay inside the guest Ubuntu.
    – Tim
    Commented Jun 20, 2016 at 20:31

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .