Mavericks window loses focus on Cmd+Tab In OS X Mavericks (10.9) I have discovered a very annoying bug.

To reproduce:


Have an external monitor connected to your Mac
Open two windows of the same application (e.g Chrome), and place one window on your Mac and the other on the external display
Click in the window on your external display to bring focus to it
⌘ Cmd+Tab ⇥ to another app (e.g Code editor)
⌘ Cmd+Tab ⇥ back to the app
Focus is now in the window on your Mac, and not on the external display (where the focus originally was). This means you have to click in the window to bring focus to it again.


Practically this means, I can no longer have a window open on my Mac while working with the same app on the external display. How can I solve this?
I can't help with this but I can confirm that this is one of many issues with multi screen multi window applications on mavericks. As he says, when you have 2 windows of the same app open on different screen, it will always give focus to the one on the primary monitor when you cmd+tab away and back to the app. This makes it rather annoying for development work when you are switching between a browser and editor regularly.