macOS: focusing of minimized window broken

This was done to fix #8913 in d7c2cdc.
Explicitly de-miniaturize before making key.
This commit is contained in:
Kovid Goyal 2025-08-23 07:32:33 +05:30
parent 1e0b3f808f
commit 21fa5bb1ce
No known key found for this signature in database
GPG key ID: 06BC317B515ACE7C

View file

@ -2291,8 +2291,13 @@ int _glfwPlatformWindowBell(_GLFWwindow* window UNUSED)
void _glfwPlatformFocusWindow(_GLFWwindow* window)
{
// Make us the active application
if (_glfwPlatformWindowIconified(window)) {
// miniaturized windows return false in canBecomeKeyWindow therefore
// unminiaturize first
[window->ns.object deminiaturize:nil];
}
if ([window->ns.object canBecomeKeyWindow]) {
// Make us the active application
[NSApp activateIgnoringOtherApps:YES];
[window->ns.object makeKeyAndOrderFront:nil];
}