Remove pointless code

This commit is contained in:
Kovid Goyal 2021-11-13 12:13:28 +05:30
parent 56e63baf5a
commit 3483722475
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -2461,9 +2461,9 @@ bool _glfwPlatformToggleFullscreen(_GLFWwindow* w, unsigned int flags) {
[[NSApplication sharedApplication] setPresentationOptions: NSApplicationPresentationDefault];
w->ns.in_traditional_fullscreen = false;
}
// for some reason despite calling this selector, the window doesnt actually get keyboard focus till you click on it.
// presumably a bug with NSWindowStyleMaskBorderless windows
[window performSelector:@selector(makeKeyAndOrderFront:) withObject:nil afterDelay:0];
// At this point keyboard input does not work even though isKeyWindow returns true
// Calling makeKeyAndOrderFront also has no effect. Neither does calling becomeKeyWindow
// Calling them after an interval with performSelector also has no effect
} else {
bool in_fullscreen = sm & NSWindowStyleMaskFullScreen;
if (!(in_fullscreen)) {