How do I stop the win+# hotkey from minimizing the focused window?

I have several monitors and use the taskbar autohide feature together with fullscreen applications, so I don't know which window currently has focus. Pressing win+{currently focused window number} makes that window minimized and it is really annoying.

There is a similar question already, but it solves this problem for mouse clicking only.


Solution 1:

It is possible to intercept the keystroke using a program like AutoHotkey. Once installed, you can write and run scripts that intercept keyboard input. The simplest kind of script is called a "hotkey". You simply state a keystroke and the desired action.

You could define the Windows+Num keystroke to do nothing, which would prevent it from being sent to Windows to toggle the visibility of the programs at that slot in the taskbar.

#1::
#2::
#3::

You will lose the capability of launching an application in the taskbar with this simple, global interception. But, I'm sure someone can recommend how to write a script that is aware of the window's focus and taskbar slot.