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

Side by Side Diff: ash/system/chromeos/power/power_status.h

Issue 380943002: Added battery level and time to the status tray's accessible name. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: removed old view before storing a new one Created 6 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 unified diff | Download patch
« no previous file with comments | « ash/ash_strings.grd ('k') | ash/system/chromeos/power/power_status.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef ASH_SYSTEM_CHROMEOS_POWER_POWER_STATUS_H_ 5 #ifndef ASH_SYSTEM_CHROMEOS_POWER_POWER_STATUS_H_
6 #define ASH_SYSTEM_CHROMEOS_POWER_POWER_STATUS_H_ 6 #define ASH_SYSTEM_CHROMEOS_POWER_POWER_STATUS_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/observer_list.h" 10 #include "base/observer_list.h"
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 // charging rate) is connected. 122 // charging rate) is connected.
123 bool IsUsbChargerConnected() const; 123 bool IsUsbChargerConnected() const;
124 124
125 // Returns true if an original spring charger is connected. 125 // Returns true if an original spring charger is connected.
126 bool IsOriginalSpringChargerConnected() const; 126 bool IsOriginalSpringChargerConnected() const;
127 127
128 // Returns the image that should be shown for the battery's current state. 128 // Returns the image that should be shown for the battery's current state.
129 gfx::ImageSkia GetBatteryImage(IconSet icon_set) const; 129 gfx::ImageSkia GetBatteryImage(IconSet icon_set) const;
130 130
131 // Returns an string describing the current state for accessibility. 131 // Returns an string describing the current state for accessibility.
132 base::string16 GetAccessibleNameString() const; 132 base::string16 GetAccessibleNameString(bool full_description) const;
133 133
134 // Updates |proto_|. Does not notify observers. 134 // Updates |proto_|. Does not notify observers.
135 void SetProtoForTesting(const power_manager::PowerSupplyProperties& proto); 135 void SetProtoForTesting(const power_manager::PowerSupplyProperties& proto);
136 136
137 protected: 137 protected:
138 PowerStatus(); 138 PowerStatus();
139 virtual ~PowerStatus(); 139 virtual ~PowerStatus();
140 140
141 private: 141 private:
142 // Overriden from PowerManagerClient::Observer. 142 // Overriden from PowerManagerClient::Observer.
143 virtual void PowerChanged( 143 virtual void PowerChanged(
144 const power_manager::PowerSupplyProperties& proto) OVERRIDE; 144 const power_manager::PowerSupplyProperties& proto) OVERRIDE;
145 145
146 ObserverList<Observer> observers_; 146 ObserverList<Observer> observers_;
147 147
148 // Current state. 148 // Current state.
149 power_manager::PowerSupplyProperties proto_; 149 power_manager::PowerSupplyProperties proto_;
150 150
151 DISALLOW_COPY_AND_ASSIGN(PowerStatus); 151 DISALLOW_COPY_AND_ASSIGN(PowerStatus);
152 }; 152 };
153 153
154 } // namespace ash 154 } // namespace ash
155 155
156 #endif // ASH_SYSTEM_CHROMEOS_POWER_POWER_STATUS_H_ 156 #endif // ASH_SYSTEM_CHROMEOS_POWER_POWER_STATUS_H_
OLDNEW
« no previous file with comments | « ash/ash_strings.grd ('k') | ash/system/chromeos/power/power_status.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698