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

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

Issue 10837067: Add accessible names to buttons in the Uber tray (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 8 years, 5 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/tray/tray_views.h ('k') | no next file » | 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 55d36fd3f65f1281584b6cccbfbe327a3c05928c..83698ec58cd64aefd666c051e12886f2165970c3 100644
--- a/ash/system/tray/tray_views.cc
+++ b/ash/system/tray/tray_views.cc
@@ -404,7 +404,8 @@ TrayPopupHeaderButton::TrayPopupHeaderButton(views::ButtonListener* listener,
int enabled_resource_id,
int disabled_resource_id,
int enabled_resource_id_hover,
- int disabled_resource_id_hover)
+ int disabled_resource_id_hover,
+ int accessible_name_id)
: views::ToggleImageButton(listener) {
ui::ResourceBundle& bundle = ui::ResourceBundle::GetSharedInstance();
SetImage(views::CustomButton::BS_NORMAL,
@@ -417,6 +418,7 @@ TrayPopupHeaderButton::TrayPopupHeaderButton(views::ButtonListener* listener,
bundle.GetImageNamed(disabled_resource_id_hover).ToImageSkia());
SetImageAlignment(views::ImageButton::ALIGN_CENTER,
views::ImageButton::ALIGN_MIDDLE);
+ SetAccessibleName(bundle.GetLocalizedString(accessible_name_id));
set_focusable(true);
set_request_focus_on_press(false);
}
« no previous file with comments | « ash/system/tray/tray_views.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698