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

Unified Diff: chrome/browser/chromeos/status/power_menu_button.h

Issue 3158014: Added tooltips to stats bar items. (Closed)
Patch Set: Fixed browser tests. Created 10 years, 4 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
Index: chrome/browser/chromeos/status/power_menu_button.h
diff --git a/chrome/browser/chromeos/status/power_menu_button.h b/chrome/browser/chromeos/status/power_menu_button.h
index 7cc55209db1f81298b2275d83b6132d39ecc96dc..abf758acb995d5d8f28fd26f80ca4dde29f04f61 100644
--- a/chrome/browser/chromeos/status/power_menu_button.h
+++ b/chrome/browser/chromeos/status/power_menu_button.h
@@ -12,6 +12,10 @@
#include "views/controls/menu/menu_2.h"
#include "views/controls/menu/view_menu_delegate.h"
+namespace base {
+class TimeDelta;
+}
+
class SkBitmap;
namespace chromeos {
@@ -64,8 +68,8 @@ class PowerMenuButton : public StatusAreaButton,
// This method will draw the |icon| in the appropriate place on the |canvas|.
void DrawPowerIcon(gfx::Canvas* canvas, SkBitmap icon);
- // Update the power icon depending on the power status.
- void UpdateIcon();
+ // Update the power icon and menu label info depending on the power status.
+ void UpdateIconAndLabelInfo();
// The number of power images.
static const int kNumPowerImages;
@@ -73,6 +77,14 @@ class PowerMenuButton : public StatusAreaButton,
// The power menu.
views::Menu2 power_menu_;
+ // Stored data gathered CrosLibrary::PowerLibrary.
+ bool battery_is_present_;
+ bool line_power_on_;
+ bool battery_fully_charged_;
+ double battery_percentage_;
+ base::TimeDelta battery_time_to_full_;
+ base::TimeDelta battery_time_to_empty_;
+
// The currently showing icon bitmap id.
int icon_id_;
« no previous file with comments | « chrome/browser/chromeos/status/network_menu_button.cc ('k') | chrome/browser/chromeos/status/power_menu_button.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698