How to prevent a fullscreen application from minimizing

I'm running my standalone fullscreen application across multiple monitors on a stretched desktop. As soon as the user moves the mouse offscreen and clicks, my application minimizes to the taskbar (Is that even supposed to happen? Offscreen clicks even though it's maximized across all monitors?).

Is there any way to prevent the application from minimizing, no matter where I click?


Enable “Visible in background” under Build settings/Standalone

Unity does not support multiple monitors by itself, as it stands right now. When a DirectX/OpenGL fullscreen application loses focus, Windows is designed to "minimize" the game, and Unity will typically "pause" the game (i.e. not update anything) when it loses focus. You're losing focus because DirectX/OpenGL applications typically only tie into the primary display adapter, ignoring any secondary ones. Unity isn't the only game/game engine that behaves like this, either, in fact the vast majority of PC games also behave this way. Unfortunately, there's really nothing you can do about this, short of writing some extension code for Unity by tapping into its low-level API's (if you have Unity Pro), though if you were even to do that, I'm not sure you could code in support for multiple monitors at that point, either.

Short answer: No. This is a fundamental "by-design" issue with Windows, and full-screen graphics applications. You might be out of luck unfortunately.

It might be a bit late, but I use this for Kiosk mode applications.

You can start the game with this batch script:

@ECHO OFF game.exe -popupwindow -screen-width 1920 -screen-height 1080

This starts the game in a window with no borders (fake full screen). This way it will not minimize when it loses focus.

Make sure you select “run in background” in the unity settings.

This is actually a pretty serious issue for us too. It basically makes running support applications impossible.