File tree 1 file changed +3
-2
lines changed
1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -125,14 +125,15 @@ - ( BOOL )userNotificationCenter:( NSUserNotificationCenter * )center shouldPres
125
125
if (@available (macOS 10.14 , *)) {
126
126
// compiled on macos 10.14+ AND running on macos 10.14+
127
127
// check the settings of effective appearance of the user
128
- return ( NSApp .effectiveAppearance .name == NSAppearanceNameDarkAqua );
128
+ NSAppearanceName appearanceName = [NSApp .effectiveAppearance bestMatchFromAppearancesWithNames: @[NSAppearanceNameAqua , NSAppearanceNameDarkAqua ]];
129
+ return ([appearanceName isEqualToString: NSAppearanceNameDarkAqua ]);
129
130
} else {
130
131
// compiled on macos 10.14+ BUT running on macos 10.13-
131
132
// DarkTheme was introduced in MacOS 10.14, fallback to light theme
132
133
return false ;
133
134
}
134
135
#endif
135
- // compiled on macos 10.13- AND running anywhere
136
+ // compiled on macos 10.13-
136
137
// NSAppearanceNameDarkAqua is not in SDK headers
137
138
// fallback to light theme
138
139
return false ;
You can’t perform that action at this time.
0 commit comments