Reworked fullscreen policy on Mac OS X.

- SDL_WINDOW_FULLSCREEN works as always (change resolution, lock to window).
- SDL_WINDOW_FULLSCREEN_DESKTOP now puts the window in its own Space, and
  hides the menu bar, but you can slide between Spaces and Command-Tab between
  apps without the window minimizing, etc.
- SDL_WINDOW_RESIZABLE windows will get the new 10.7+ "toggle fullscreen"
  window decoration and menubar item. As far as the app is concerned, this is
  no different than resizing a window, but it gives the end-user more power.
- The hint for putting fullscreen windows into the Spaces system is gone,
  since Spaces can't enforce the requested resolution. It's a perfect match
  for FULLSCREEN_DESKTOP, though, so this is all automated now.
This commit is contained in:
Ryan C. Gordon 2014-03-02 12:45:51 -05:00
parent 88bdcd6a28
commit afa70ff8df
2 changed files with 35 additions and 39 deletions

View file

@ -200,17 +200,6 @@ extern "C" {
*/
#define SDL_HINT_VIDEO_MINIMIZE_ON_FOCUS_LOSS "SDL_VIDEO_MINIMIZE_ON_FOCUS_LOSS"
/**
* \brief Set whether windows go fullscreen in their own spaces on Mac OS X
*
* This variable can be set to the following values:
* "0" - Fullscreen windows will use the classic fullscreen mode
* "1" - Fullscreen windows will use fullscreen spaces
*
* By default SDL will use the classic fullscreen mode.
*/
#define SDL_HINT_VIDEO_FULLSCREEN_SPACES "SDL_VIDEO_FULLSCREEN_SPACES"
/**
* \brief A variable controlling whether the idle timer is disabled on iOS.
*