This repository was archived by the owner on Sep 2, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +5
-7
lines changed Expand file tree Collapse file tree 2 files changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -222,9 +222,9 @@ -(void)windowTitleDidChange:(NSString*)title {
222
222
}
223
223
224
224
-(BOOL )isRunningOnYosemite {
225
- NSDictionary * dict = [ NSDictionary dictionaryWithContentsOfFile: @" /System/Library/CoreServices/SystemVersion.plist " ];
226
- NSString *version = [dict objectForKey :@" ProductVersion " ];
227
- return ([version hasPrefix: @" 10.10 " ]) ;
225
+ // this API returns nil prior to Yosemite
226
+ NSDictionary * dict = [ NSDictionary dictionaryWithContentsOfFile :@" /System/Library/CoreServices/SystemVersion.plist " ];
227
+ return dict != nil ;
228
228
}
229
229
230
230
- (BOOL )isFullScreenSupported {
Original file line number Diff line number Diff line change @@ -165,14 +165,12 @@ - (void)setIsReallyClosing {
165
165
isReallyClosing = true ;
166
166
}
167
167
168
- //
169
168
-(BOOL )isRunningOnYosemite {
169
+ // this API returns nil prior to Yosemite
170
170
NSDictionary * dict = [NSDictionary dictionaryWithContentsOfFile: @" /System/Library/CoreServices/SystemVersion.plist" ];
171
- NSString *version = [dict objectForKey: @" ProductVersion" ];
172
- return ([version hasPrefix: @" 10.10" ]);
171
+ return dict != nil ;
173
172
}
174
173
175
-
176
174
- (BOOL )isFullScreenSupported {
177
175
// Return False on Yosemite so we
178
176
// don't draw our own full screen button
You can’t perform that action at this time.
0 commit comments