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

Unified Diff: ui/views/controls/button/text_button.cc

Issue 11558006: Fix label color in TextButtonBase (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years 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/native_theme/native_theme_win.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/button/text_button.cc
===================================================================
--- ui/views/controls/button/text_button.cc (revision 172348)
+++ ui/views/controls/button/text_button.cc (working copy)
@@ -207,21 +207,13 @@
show_multiple_icon_states_(true),
is_default_(false),
multi_line_(false),
- color_(ui::NativeTheme::instance()->GetSystemColor(
- ui::NativeTheme::kColorId_TextButtonEnabledColor)),
- color_enabled_(ui::NativeTheme::instance()->GetSystemColor(
- ui::NativeTheme::kColorId_TextButtonEnabledColor)),
- color_disabled_(ui::NativeTheme::instance()->GetSystemColor(
- ui::NativeTheme::kColorId_TextButtonDisabledColor)),
- color_highlight_(ui::NativeTheme::instance()->GetSystemColor(
- ui::NativeTheme::kColorId_TextButtonHighlightColor)),
- color_hover_(ui::NativeTheme::instance()->GetSystemColor(
- ui::NativeTheme::kColorId_TextButtonHoverColor)),
use_enabled_color_from_theme_(true),
use_disabled_color_from_theme_(true),
use_highlight_color_from_theme_(true),
use_hover_color_from_theme_(true) {
SetText(text);
+ // OnNativeThemeChanged sets the color member variables.
+ TextButtonBase::OnNativeThemeChanged(GetNativeTheme());
SetAnimationDuration(kHoverAnimationDurationMs);
}
« no previous file with comments | « ui/native_theme/native_theme_win.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698