macOS: fix window level issue when changing active app while in fullscreen mode (#1192)

This commit is contained in:
ManoloFLTK 2025-01-28 12:14:16 +01:00
parent bfdae6d151
commit ad333e2c8e

View File

@ -1502,7 +1502,11 @@ static FLWindowDelegate *flwindowdelegate_instance = nil;
FLWindow *nsw = (FLWindow*)[notif object];
Fl_Window *w = [nsw getFl_Window];
/* Restore previous fullscreen level */
if (w->fullscreen_active() && fl_mac_os_version < 100700) {
if (w->fullscreen_active() && (fl_mac_os_version < 100700
# if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_7
|| !(nsw.styleMask & NSWindowStyleMaskFullScreen)
#endif
)) {
[nsw setLevel:NSStatusWindowLevel];
fixup_window_levels();
}