Alt-tab in HOST not working; VM guest window frame flashes briefly but focus remains / reverts to VM

Discussions related to using VirtualBox on Windows hosts.
Post Reply
James Ross
Posts: 4
Joined: 17. Jan 2018, 20:02

Alt-tab in HOST not working; VM guest window frame flashes briefly but focus remains / reverts to VM

Post by James Ross »

I have search for this problem but have gotten no hits on it. So I wonder if anyone else is experiencing this. If someone could confirm they are experiencing this same bug, I will file a bug report. Thanks!

Host: Windows 8.1 Pro
Guest: does not mater (have tried Fedore/OpenSUSE/DOS)

Tested with VirtualBox-5.2.6-120293-Win.exe / VirtualBox-5.1.32-120294-Win.exe / VirtualBox-5.0.40-115130-Win.exe – all these HAVE the problem.

Tested with VirtualBox-4.3.40-110317-Win.exe – does NOT have the problem.

Regardless if “Auto Capture Keyboard” is on or off, alt-tab does not work properly when trying to switch away from the VM.

If “Auto Capture Keyboard” is off VM guest window frame flashes briefly but focus remains / reverts to VM immediately

If “Auto Capture Keyboard” is on then Alt-Tab works fine within the VM but when I hit the Right-Ctrl and do Alt-Tab to leave the VM to go to another app, again VM guest window frame flashes but focus reverts to VM immediately.

Must use mouse to move off VM either way.

If I hold the alt-tab key down, it will after a second or so, move off the VM, but that is not a workaround as the alt-tab window of Windows will rapidly cycle through all my open windows as opposed to returning to the last app.

Thanks
James
socratis
Site Moderator
Posts: 27330
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: Alt-tab in HOST not working; VM guest window frame flashes briefly but focus remains / reverts t

Post by socratis »

James Ross wrote:alt-tab does not work properly when trying to switch away from the VM.
It never worked and it will never work the way you're thinking it should/could work; it's by design. The keyboard is directed to whoever has the focus. If your VM has the focus, the VM gets the Alt+Tab. If your host has the focus, your host gets the Alt+Tab. Simple.

If you want to switch the focus, simply press the HostKey once (if your VM has the focus) and then Alt+Tab. If you want to switch to the VM (if your host has the focus), keep pressing Alt+Tab until you switch to the VM, and then press Alt+Tab to switch to applications within your guest.
James Ross wrote: If someone could confirm they are experiencing this same bug, I will file a bug report.
It's not a bug, it's by design. And you don't want to file a bug that's going to be closed immediately as [WontFix] or [Invalid].

To recap; to switch away from your VM and switch apps it the host press HostKey (once), and then Alt+Tab. You'll get used to it really soon...
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.
James Ross
Posts: 4
Joined: 17. Jan 2018, 20:02

Re: Alt-tab in HOST not working; VM guest window frame flashes briefly but focus remains / reverts t

Post by James Ross »

It never worked and it will never work the way you're thinking it should/could work; it's by design.
That is ridiculous that it is by design.

First of all I clearly state that it works as it should in version 4.3.40 – so I am assuming the bug was introduced w/ version 5.x.

I have been using VirtualBox on and off since versions 3.x and has never done this before.

Secondly, why would the VM window frame flash when you hit alt-tab and just stay on the window?

If “Auto Capture Keyboard” is OFF what is the purpose of the frame flashing? Why and how is that by design?

If “Auto Capture Keyboard” is ON alt-tab works within the VM as it should. SO when you hit the Ctrl-Key (HOST Key) to release the Auto Capture Keyboard what would be the purpose of that if hitting Alt-Tab then to move away from the VM does nothing (minus the slight flash)… what’s the reasoning for that not working in 5.x and it has worked all along before?

Anyone else want to chime in to confirm they are experiencing the same issue before I file a bug report?

Thanks
James
James Ross
Posts: 4
Joined: 17. Jan 2018, 20:02

Re: Alt-tab in HOST not working; VM guest window frame flashes briefly but focus remains / reverts t

Post by James Ross »

I just loaded VirtualBox 5.2.6 on a DELL Notebook running Windows 10 Home and ran a single VM (FreeDOS -- easiest to setup) and it does NOT have this issue. Alt Tab from the HOST works as it's suppose to. I will try it again on a least one Linux guest w/ guest additions installed.

AND then later I'll try out on a Windows 7 PC...

It's possible it's either a Windows 8.1 issue -- OR an issue w/ just my Windows 8.1 computer.
socratis
Site Moderator
Posts: 27330
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: Alt-tab in HOST not working; VM guest window frame flashes briefly but focus remains / reverts t

Post by socratis »

James Ross wrote:It's possible it's either a Windows 8.1 issue -- OR an issue w/ just my Windows 8.1 computer.
Or the fact that Alt-Tab is not used in FreeDOS?
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.
James Ross
Posts: 4
Joined: 17. Jan 2018, 20:02

Re: Alt-tab in HOST not working; VM guest window frame flashes briefly but focus remains / reverts t

Post by James Ross »

Or the fact that Alt-Tab is not used in FreeDOS?
With all due respect -- I believe that this shows you still don't understand what it is that I am saying... I've phrased it and re-phrased it the best I can and I don't know how I can make it any clearer.

However, you do understand how it's supposed to work, so let's try this angle, since you did say this in a previous response:
To recap; to switch away from your VM and switch apps it the host press HostKey (once), and then Alt+Tab. You'll get used to it really soon...
Yes, yes, yes!! that is how it's supposed to work -- but it does NOT work like that on my Windows 8.1 PC ... when I "press HostKey (once), and then Alt+Tab" it does *NOT* as you say "switch away from your VM and switch apps".

Instead the frame of the Windows window of the VM flashes one time and it does NOT switch away back to another Windows app I have running. Instead I am still on the VM with keyboard focus on the VM.

Also, if Windows 8.1 (at least mine) and Windows 10.0 work differently w/ FreeDOS -- how could that be related to it being FreeDOS?

You might want to wait for me to do some more experimenting (later today or tomorrow) before you respond again, up to you.

Thanks
James
xoblautriv666
Posts: 1
Joined: 14. Apr 2018, 20:22

Re: Alt-tab in HOST not working; VM guest window frame flashes briefly but focus remains / reverts t

Post by xoblautriv666 »

I confirm the problem exists.
I've just installed VirtualBox 5.2 on my Windows 8.0 machine, and the behaviour matches James Ross' description:

With Auto capture is on I switch into a guest (linux or windows, does not matter).
Then I try to get out of it by pressing Host (set to right alt or to application, does not matter) and then alt-tab away.
After pressing Host I can see that the mouse cursor becomes host's, I can move it away (my guests not running vm integration yet).
But when I try to alt-tab the guest screen frame flashes quickly and stays, no usual alt-tab splash can be seen.

That was not the case on my previous virtualbox 4.2.
Host then Alt-tab combination worked impeccably.

So far the only workaround I found is to ctrl-esc after Host and then alt-tab.

Some guy on superuser-com (look up the title like "virtualbox host key can't get out of scale mode", I can't post urls yet)
reports something similar on Windows 8.1 after updates, and mentions broken alt-tab event sequence, but the post is quite old.
Post Reply