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

Unified Diff: ui/views/controls/menu/menu_item_view.cc

Issue 2382443007: Clean up NativeTheme (particularly CommonTheme). (Closed)
Patch Set: share color constant Created 4 years, 2 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 | « ui/views/controls/menu/menu_delegate.cc ('k') | ui/views/style/platform_style.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/menu/menu_item_view.cc
diff --git a/ui/views/controls/menu/menu_item_view.cc b/ui/views/controls/menu/menu_item_view.cc
index 15ae4b80256476c2a32695a39ca8f6e44ef29ba4..73fc3039650a4d38bd2908439eb40707aa0585c9 100644
--- a/ui/views/controls/menu/menu_item_view.cc
+++ b/ui/views/controls/menu/menu_item_view.cc
@@ -783,12 +783,11 @@ void MenuItemView::PaintButton(gfx::Canvas* canvas, PaintButtonMode mode) {
ui::NativeTheme::kColorId_SelectedMenuItemForegroundColor:
ui::NativeTheme::kColorId_EnabledMenuItemForegroundColor;
} else {
- bool emphasized = delegate &&
- delegate->GetShouldUseDisabledEmphasizedForegroundColor(
- GetCommand());
- color_id = emphasized ?
- ui::NativeTheme::kColorId_DisabledEmphasizedMenuItemForegroundColor :
- ui::NativeTheme::kColorId_DisabledMenuItemForegroundColor;
+ bool emphasized =
+ delegate && delegate->GetShouldUseNormalForegroundColor(GetCommand());
+ color_id = emphasized
+ ? ui::NativeTheme::kColorId_EnabledMenuItemForegroundColor
+ : ui::NativeTheme::kColorId_DisabledMenuItemForegroundColor;
}
SkColor fg_color = native_theme->GetSystemColor(color_id);
SkColor override_foreground_color;
« no previous file with comments | « ui/views/controls/menu/menu_delegate.cc ('k') | ui/views/style/platform_style.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698