I guess I should check if [NSApplication presentationOptions]
contains NSFullScreenModeApplicationPresentationOptions
, but how do I achieve that?
EDIT: using [NSApplication presentationOptions]
doesn't work as in my document-based app there might be some documents in fullscreen and others not. I'm now looking for another solution. I'm wondering why there isn't a property called [NSWindow isFullscreen]
or something like that.
I was just looking for a solution myself and based on Matthieu's answer I created a category on NSWindow that works fine for me.
@interface NSWindow (FullScreen)
- (BOOL)mn_isFullScreen;
@end
@implementation NSWindow (FullScreen)
- (BOOL)mn_isFullScreen
{
return (([self styleMask] & NSFullScreenWindowMask) == NSFullScreenWindowMask);
}
@end
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With