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

Unified Diff: chrome/browser/chromeos/network_menu_button.h

Issue 315008: New wifi icons animation. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 2 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/network_menu_button.h
===================================================================
--- chrome/browser/chromeos/network_menu_button.h (revision 30284)
+++ chrome/browser/chromeos/network_menu_button.h (working copy)
@@ -18,6 +18,10 @@
class Browser;
class SkBitmap;
+namespace gfx {
+class Canvas;
+}
+
// The network menu button in the status area.
// This class will handle getting the wifi networks and populating the menu.
// It will also handle the status icon changing and connecting to another
@@ -59,20 +63,29 @@
// CrosNetworkLibrary::Observer implementation.
virtual void NetworkChanged(CrosNetworkLibrary* obj);
+ virtual void NetworkTraffic(CrosNetworkLibrary* cros,
+ int traffic_type);
+ protected:
+ // StatusAreaButton implementation.
+ virtual void DrawIcon(gfx::Canvas* canvas);
+
private:
// views::ViewMenuDelegate implementation.
virtual void RunMenu(views::View* source, const gfx::Point& pt);
- // Update the icon to either the connecting, connected, or disconnected icon.
- void UpdateIcon();
-
// Set to true if we are currently refreshing the menu.
bool refreshing_menu_;
// The number of wifi strength images.
static const int kNumWifiImages;
+ // The minimum opacity of the wifi bars.
+ static const int kMinOpacity;
+
+ // The maximum opacity of the wifi bars.
+ static const int kMaxOpacity;
+
// A list of wifi networks.
WifiNetworkVector wifi_networks_;
@@ -86,9 +99,15 @@
gfx::NativeWindow browser_window_;
// The throb animation that does the wifi connecting animation.
- ThrobAnimation animation_;
+ ThrobAnimation animation_connecting_;
- // The duration of the wifi connecting icon throbbing in milliseconds.
+ // The throb animation that does the downloading animation.
+ ThrobAnimation animation_downloading_;
+
+ // The throb animation that does the uploading animation.
+ ThrobAnimation animation_uploading_;
+
+ // The duration of the icon throbbing in milliseconds.
static const int kThrobDuration;
DISALLOW_COPY_AND_ASSIGN(NetworkMenuButton);

Powered by Google App Engine
This is Rietveld 408576698