Index: ash/system/chromeos/power/power_status.cc |
diff --git a/ash/system/chromeos/power/power_status.cc b/ash/system/chromeos/power/power_status.cc |
index 8940e9ecb472b8b021a9e7270530541ee6f47a0c..591c31887b3eb0b45434ee3833907dbd038c625f 100644 |
--- a/ash/system/chromeos/power/power_status.cc |
+++ b/ash/system/chromeos/power/power_status.cc |
@@ -235,7 +235,8 @@ gfx::ImageSkia PowerStatus::GetBatteryImage(IconSet icon_set) const { |
return gfx::ImageSkiaOperations::ExtractSubset(*all.ToImageSkia(), region); |
} |
-base::string16 PowerStatus::GetAccessibleNameString() const { |
+base::string16 PowerStatus::GetAccessibleNameString( |
+ bool full_description) const { |
ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance(); |
if (IsBatteryFull()) { |
return rb.GetLocalizedString( |
@@ -247,6 +248,9 @@ base::string16 PowerStatus::GetAccessibleNameString() const { |
IDS_ASH_STATUS_TRAY_BATTERY_PERCENT_CHARGING_ACCESSIBLE : |
IDS_ASH_STATUS_TRAY_BATTERY_PERCENT_ACCESSIBLE, |
base::IntToString16(GetRoundedBatteryPercent())); |
+ if (!full_description) |
+ return battery_percentage_accessible; |
+ |
base::string16 battery_time_accessible = base::string16(); |
const base::TimeDelta time = IsBatteryCharging() ? GetBatteryTimeToFull() : |
GetBatteryTimeToEmpty(); |