From Garry's Mod
Returns whether or not the game window has focus.
Returns true 100% of the time on OS X.
This function does not work on dedicated servers and will instead return no value.
This will return true when minimized in windowed-mode.
Issue Tracker: #2424
Whether or not the game window has focus.