OSX: as an prerequisite to make Dalai's upcoming "area_fullsceen" work,

make sure the window states are correct in the lion_fs animation phase.
This also assures the CTX_wm_window(C) is okay.
This commit is contained in:
Jens Verwiebe 2014-10-10 12:56:58 +02:00
parent e640b4fb72
commit fd6537a53a

@ -870,8 +870,13 @@ GHOST_TWindowState GHOST_WindowCocoa::getState() const
if (masks & NSFullScreenWindowMask) { if (masks & NSFullScreenWindowMask) {
// Lion style fullscreen // Lion style fullscreen
if (!m_immediateDraw) {
state = GHOST_kWindowStateFullScreen; state = GHOST_kWindowStateFullScreen;
} }
else {
state = GHOST_kWindowStateNormal;
}
}
else else
#endif #endif
if (m_fullScreen) { if (m_fullScreen) {
@ -883,9 +888,14 @@ GHOST_TWindowState GHOST_WindowCocoa::getState() const
else if ([m_window isZoomed]) { else if ([m_window isZoomed]) {
state = GHOST_kWindowStateMaximized; state = GHOST_kWindowStateMaximized;
} }
else {
if (m_immediateDraw) {
state = GHOST_kWindowStateFullScreen;
}
else { else {
state = GHOST_kWindowStateNormal; state = GHOST_kWindowStateNormal;
} }
}
[pool drain]; [pool drain];
return state; return state;
} }