Windows – When using CMD-Tab, how to re-open the app’s main window

application-switcherdockkeyboardwindow-managerwindows

I hit this problem often when interacting with some Apple applications, mainly Messages and iTunes.

After starting a song with iTunes, to clear my screen and get back to work I close the iTunes window with CMD-W. The iTunes application is still running in my Dock and playing music.

After some time, I want to switch to a different album. I CMD-Tab to select the iTunes application. iTunes is focused in the menu bar. But no window is shown, because I previously closed the window.

This workflow occurs for all apps, and is not usually a problem. If I switch to Safari and no window is open, I simply press CMD-T or CMD-N to open a new tab or new window.

With iTunes, I press CMD-N and nothing happens. No iTunes window is created or shown. The Application is focused, but the main window is not re-opened if it is currently closed.

I end up clicking on the Dock, which (in addition to focusing the application) opens a new iTunes window if that window was previously closed.

This breaks my (usually more efficient) CMD-Tab workflow. If I'm forced to click the iTunes dock icon, I may as well just click the dock icon from the start and forgo the keyboard shortcut.

Messages has a similar problem. If I receive a desktop notification and use CMD-Tab to open Messages to respond, the application will be focused but no window will be opened. I can press CMD-N, which in Message's case does open a new window, but the "new message" cell will be opened rather than the existing conversation I had open and now want to respond to.

When clicking the Dock icon or opening the app via a Spotlight Search, if the main window is not open then it will be re-opened. Is there a way to force this behavior for CMD-Tab app selection?

How do I show the main window when the Application is focused via CMD-Tab?

Best Answer

Several applications including iTunes let you switch views by using CMD +<number>. CMD + 0 will give you the main window. But some applications like iTunes offer different views.

Just try CMD+tab to iTunes and then variate between CMD + 1 to 9 to see which view you like. In the screenshot below you can see the different options for iTunes. Messages only has the option CMD + 0.

enter image description here