Cocoa: Fix window rect on leaving video mode

Fixes #748.
This commit is contained in:
Camilla Löwy
2017-03-14 21:21:29 +01:00
parent 21355e31db
commit 7c88c92778
2 changed files with 6 additions and 0 deletions
+4
View File
@@ -1310,6 +1310,10 @@ void _glfwPlatformSetWindowMonitor(_GLFWwindow* window,
_glfwInputWindowMonitorChange(window, monitor);
// HACK: Allow the state cached in Cocoa to catch up to reality
// TODO: Solve this in a less terrible way
_glfwPlatformPollEvents();
const NSUInteger styleMask = getStyleMask(window);
[window->ns.object setStyleMask:styleMask];
[window->ns.object makeFirstResponder:window->ns.view];