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

Unified Diff: ash/system/tray/tray_views.cc

Issue 12330002: Add views::Button style enum for LabelButton [native] styling, etc. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Sync and merge. Created 7 years, 10 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 | « ash/system/logout_button/tray_logout_button.cc ('k') | ash/system/user/tray_user.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/system/tray/tray_views.cc
diff --git a/ash/system/tray/tray_views.cc b/ash/system/tray/tray_views.cc
index 6065d34e3c6d170b3449cb36a854f1dfaf3f6783..6e2d2926c7a34ba03b6bea5e4e5b8777d051640e 100644
--- a/ash/system/tray/tray_views.cc
+++ b/ash/system/tray/tray_views.cc
@@ -145,17 +145,18 @@ void FixedSizedScrollView::OnPaintFocusBorder(gfx::Canvas* canvas) {
////////////////////////////////////////////////////////////////////////////////
// TrayPopupLabelButtonBorder
-TrayPopupLabelButtonBorder::TrayPopupLabelButtonBorder() {
- SetPainter(views::CustomButton::STATE_NORMAL,
+TrayPopupLabelButtonBorder::TrayPopupLabelButtonBorder()
+ : LabelButtonBorder(views::Button::STYLE_TEXTBUTTON) {
+ SetPainter(views::Button::STATE_NORMAL,
views::Painter::CreateImageGridPainter(
kTrayPopupLabelButtonBorderImagesNormal));
- SetPainter(views::CustomButton::STATE_DISABLED,
+ SetPainter(views::Button::STATE_DISABLED,
views::Painter::CreateImageGridPainter(
kTrayPopupLabelButtonBorderImagesNormal));
- SetPainter(views::CustomButton::STATE_HOVERED,
+ SetPainter(views::Button::STATE_HOVERED,
views::Painter::CreateImageGridPainter(
kTrayPopupLabelButtonBorderImagesHovered));
- SetPainter(views::CustomButton::STATE_PRESSED,
+ SetPainter(views::Button::STATE_PRESSED,
views::Painter::CreateImageGridPainter(
kTrayPopupLabelButtonBorderImagesHovered));
}
@@ -236,13 +237,13 @@ TrayPopupHeaderButton::TrayPopupHeaderButton(views::ButtonListener* listener,
int accessible_name_id)
: views::ToggleImageButton(listener) {
ui::ResourceBundle& bundle = ui::ResourceBundle::GetSharedInstance();
- SetImage(views::CustomButton::STATE_NORMAL,
+ SetImage(views::Button::STATE_NORMAL,
bundle.GetImageNamed(enabled_resource_id).ToImageSkia());
- SetToggledImage(views::CustomButton::STATE_NORMAL,
+ SetToggledImage(views::Button::STATE_NORMAL,
bundle.GetImageNamed(disabled_resource_id).ToImageSkia());
- SetImage(views::CustomButton::STATE_HOVERED,
+ SetImage(views::Button::STATE_HOVERED,
bundle.GetImageNamed(enabled_resource_id_hover).ToImageSkia());
- SetToggledImage(views::CustomButton::STATE_HOVERED,
+ SetToggledImage(views::Button::STATE_HOVERED,
bundle.GetImageNamed(disabled_resource_id_hover).ToImageSkia());
SetImageAlignment(views::ImageButton::ALIGN_CENTER,
views::ImageButton::ALIGN_MIDDLE);
« no previous file with comments | « ash/system/logout_button/tray_logout_button.cc ('k') | ash/system/user/tray_user.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698