File tree Expand file tree Collapse file tree 3 files changed +12
-3
lines changed
Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -734,7 +734,12 @@ - (void)setNeedsDisplayFromRow:(int)row column:(int)col toRow:(int)row2
734734- (void )drawRect : (NSRect )rect
735735{
736736 NSGraphicsContext *context = [NSGraphicsContext currentContext ];
737+ #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_10
737738 CGContextRef ctx = context.CGContext ;
739+ #else
740+ CGContextRef ctx = [context graphicsPort ];
741+ #endif
742+
738743 [context setShouldAntialias: antialias];
739744 {
740745 CGColorSpaceRef colorSpace = CGColorSpaceCreateWithName (kCGColorSpaceSRGB );
Original file line number Diff line number Diff line change @@ -382,7 +382,7 @@ - (NSEdgeInsets) viewOffset {
382382
383383#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_VERSION_12_0)
384384 // Account for newer MacBook Pro's which have a notch, which can be queried using the safe area API.
385- if ([ NSScreen instancesRespondToSelector: @selector ( safeAreaInsets )] ) {
385+ if (@ available (macos 12.0 , *) ) {
386386 const int safeAreaBehavior = [[NSUserDefaults standardUserDefaults ]
387387 integerForKey: MMNonNativeFullScreenSafeAreaBehaviorKey];
388388
Original file line number Diff line number Diff line change @@ -571,8 +571,12 @@ - (void)refreshApperanceMode
571571 // has selected as a preference.
572572
573573 // Transparent title bar setting
574- decoratedWindow.titlebarAppearsTransparent = [[NSUserDefaults standardUserDefaults ]
575- boolForKey: MMTitlebarAppearsTransparentKey];
574+ #if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_10
575+ if (@available (macos 10.10 , *)) {
576+ decoratedWindow.titlebarAppearsTransparent = [[NSUserDefaults standardUserDefaults ]
577+ boolForKey: MMTitlebarAppearsTransparentKey];
578+ }
579+ #endif
576580
577581 // No title bar setting
578582 if ([[NSUserDefaults standardUserDefaults ]
You can’t perform that action at this time.
0 commit comments