Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/intern
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@gmail.com>2014-02-03 19:45:51 +0400
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2014-02-03 19:48:31 +0400
commit3314165a668b46f5a0863d99a3f5b2bc602a41ff (patch)
tree109a3fd9dbffeac1f7430d65d544f234fa235e34 /intern
parent0d7586739a749b9fa2fa82b014d71ad01a97f211 (diff)
Fix T38452: on OS X 10.9, now always use Lion style fullscreen.
On earlier versions there is no proper multi-monitor support, so we leave the choice still. But for 10.9 this just interacts better with other elements like spaces and the dock.
Diffstat (limited to 'intern')
-rw-r--r--intern/ghost/intern/GHOST_WindowCocoa.mm12
1 files changed, 11 insertions, 1 deletions
diff --git a/intern/ghost/intern/GHOST_WindowCocoa.mm b/intern/ghost/intern/GHOST_WindowCocoa.mm
index de2ae79d0b6..93036da4dae 100644
--- a/intern/ghost/intern/GHOST_WindowCocoa.mm
+++ b/intern/ghost/intern/GHOST_WindowCocoa.mm
@@ -1038,6 +1038,16 @@ GHOST_TSuccess GHOST_WindowCocoa::setState(GHOST_TWindowState state)
NSUInteger masks = [m_window styleMask];
if (!m_fullScreen && !(masks & NSFullScreenWindowMask)) {
+ /* Starting with 10.9, we always use Lion fullscreen, since it
+ * now has proper multi-monitor support for fullscreen */
+ struct { SInt32 major, minor; } systemversion;
+ Gestalt(gestaltSystemVersionMajor, &systemversion.major);
+ Gestalt(gestaltSystemVersionMinor, &systemversion.minor);
+
+ if (systemversion.major > 10 || (systemversion.major == 10 && systemversion.minor >= 9)) {
+ [m_window toggleFullScreen:nil];
+ break;
+ }
#else
if (!m_fullScreen) {
#endif
@@ -1100,7 +1110,7 @@ GHOST_TSuccess GHOST_WindowCocoa::setState(GHOST_TWindowState state)
m_systemCocoa->handleWindowEvent(GHOST_kEventWindowSize, this);
[pool drain];
- }
+ }
break;
}
case GHOST_kWindowStateNormal: