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

Unified Diff: ui/native_theme/native_theme_mac.mm

Issue 2288003002: Delete IsAtLeastOS10_9() and IsAtMostOS10_9() (Closed)
Patch Set: Clean up a duplicate check, delete a stray ! Created 4 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
Index: ui/native_theme/native_theme_mac.mm
diff --git a/ui/native_theme/native_theme_mac.mm b/ui/native_theme/native_theme_mac.mm
index 5f1f8d9d83cc11ef14e0c7e31ca0fec6b37b8563..36e04dacf781176e4350dd60e9fad8392798e0c5 100644
--- a/ui/native_theme/native_theme_mac.mm
+++ b/ui/native_theme/native_theme_mac.mm
@@ -181,8 +181,8 @@ SkColor NativeThemeMac::GetSystemColor(ColorId color_id) const {
case kColorId_MenuBackgroundColor:
return kMenuPopupBackgroundColor;
case kColorId_MenuSeparatorColor:
- return base::mac::IsOS10_9() ? kMenuSeparatorColorMavericks
- : kMenuSeparatorColor;
+ return base::mac::IsAtLeastOS10_10() ? kMenuSeparatorColor
+ : kMenuSeparatorColorMavericks;
case kColorId_MenuBorderColor:
return kMenuBorderColor;
@@ -243,10 +243,10 @@ void NativeThemeMac::PaintMenuPopupBackground(
const MenuBackgroundExtraParams& menu_background) const {
SkPaint paint;
paint.setAntiAlias(true);
- if (base::mac::IsOS10_9())
- paint.setColor(kMenuPopupBackgroundColorMavericks);
- else
+ if (base::mac::IsAtLeastOS10_10())
paint.setColor(kMenuPopupBackgroundColor);
+ else
+ paint.setColor(kMenuPopupBackgroundColorMavericks);
const SkScalar radius = SkIntToScalar(menu_background.corner_radius);
SkRect rect = gfx::RectToSkRect(gfx::Rect(size));
canvas->drawRoundRect(rect, radius, radius, paint);

Powered by Google App Engine
This is Rietveld 408576698