mirror of
https://github.com/Ryujinx/SDL.git
synced 2025-01-23 14:31:06 +00:00
macOS: Fix menubar items being enabled when they shouldn't be.
This commit is contained in:
parent
b959be2569
commit
d7ae313134
|
@ -80,14 +80,14 @@
|
||||||
if ([menuItem action] == @selector(toggleFullScreen:)) {
|
if ([menuItem action] == @selector(toggleFullScreen:)) {
|
||||||
SDL_Window *window = [self findSDLWindow];
|
SDL_Window *window = [self findSDLWindow];
|
||||||
if (window == NULL) {
|
if (window == NULL) {
|
||||||
return YES;
|
return NO;
|
||||||
} else if ((window->flags & (SDL_WINDOW_FULLSCREEN|SDL_WINDOW_FULLSCREEN_DESKTOP)) != 0) {
|
} else if ((window->flags & (SDL_WINDOW_FULLSCREEN|SDL_WINDOW_FULLSCREEN_DESKTOP)) != 0) {
|
||||||
return NO;
|
return NO;
|
||||||
} else if ((window->flags & SDL_WINDOW_RESIZABLE) == 0) {
|
} else if ((window->flags & SDL_WINDOW_RESIZABLE) == 0) {
|
||||||
return NO;
|
return NO;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return YES;
|
return [super validateMenuItem:menuItem];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (BOOL)canBecomeKeyWindow
|
- (BOOL)canBecomeKeyWindow
|
||||||
|
|
Loading…
Reference in a new issue