Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1982)

Unified Diff: Source/platform/mac/ThemeMac.mm

Issue 1286233004: Revert of Fix the mechanism by which Blink determines OSX version number. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/platform/blink_platform.gypi ('k') | Source/platform/mac/VersionUtilMac.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/mac/ThemeMac.mm
diff --git a/Source/platform/mac/ThemeMac.mm b/Source/platform/mac/ThemeMac.mm
index 3b120064faa4037fda1765ac173b32be2f49834d..5218678ef87b1eac58840c2a9c3383cd368220ad 100644
--- a/Source/platform/mac/ThemeMac.mm
+++ b/Source/platform/mac/ThemeMac.mm
@@ -30,7 +30,6 @@
#import "platform/graphics/GraphicsContextStateSaver.h"
#import "platform/mac/BlockExceptions.h"
#import "platform/mac/LocalCurrentGraphicsContext.h"
-#import "platform/mac/VersionUtilMac.h"
#import "platform/mac/WebCoreNSCellExtras.h"
#import "platform/scroll/ScrollableArea.h"
#include "wtf/StdLibExtras.h"
@@ -697,16 +696,23 @@
}
}
+#ifndef NSAppKitVersionNumber10_7
+#define NSAppKitVersionNumber10_7 1138
+#endif
+#ifndef NSAppKitVersionNumber10_9
+#define NSAppKitVersionNumber10_9 1265
+#endif
+
bool ThemeMac::drawWithFrameDrawsFocusRing()
{
#if defined(MAC_OS_X_VERSION_10_8) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_8
// If compiling against an OSX 10.8+ SDK, only 10.7 and older OSes will draw a
// focus ring with the frame.
- return IsOSLionOrEarlier();
+ return floor(NSAppKitVersionNumber) <= NSAppKitVersionNumber10_7;
#else
// If compiling an OSX 10.7 or older SDK, OSes up through 10.9 will draw a focus
// ring with the frame.
- return IsOSMavericksOrEarlier();
+ return floor(NSAppKitVersionNumber) <= NSAppKitVersionNumber10_9;
#endif
}
« no previous file with comments | « Source/platform/blink_platform.gypi ('k') | Source/platform/mac/VersionUtilMac.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698