Index: ash/system/chromeos/network/tray_network.h |
diff --git a/ash/system/chromeos/network/tray_network.h b/ash/system/chromeos/network/tray_network.h |
index 3105c1fe4e79cca900166225953f50932adfbe4b..773605610c5d8955510a2542fd9e63ffdec93c7e 100644 |
--- a/ash/system/chromeos/network/tray_network.h |
+++ b/ash/system/chromeos/network/tray_network.h |
@@ -9,6 +9,7 @@ |
#include "ash/system/chromeos/network/network_icon.h" |
#include "ash/system/chromeos/network/network_observer.h" |
+#include "ash/system/chromeos/network/tray_network_state_observer.h" |
#include "ash/system/tray/system_tray_item.h" |
#include "base/memory/scoped_ptr.h" |
#include "base/time.h" |
@@ -32,7 +33,8 @@ class NetworkTrayView; |
} |
class TrayNetwork : public SystemTrayItem, |
- public NetworkObserver { |
+ public NetworkObserver, |
+ public TrayNetworkStateObserver::Delegate { |
public: |
explicit TrayNetwork(SystemTray* system_tray); |
virtual ~TrayNetwork(); |
@@ -40,7 +42,7 @@ class TrayNetwork : public SystemTrayItem, |
tray::NetworkDetailedView* detailed() { return detailed_; } |
void set_request_wifi_view(bool b) { request_wifi_view_ = b; } |
- // Overridden from SystemTrayItem. |
+ // SystemTrayItem |
virtual views::View* CreateTrayView(user::LoginStatus status) OVERRIDE; |
virtual views::View* CreateDefaultView(user::LoginStatus status) OVERRIDE; |
virtual views::View* CreateDetailedView(user::LoginStatus status) OVERRIDE; |
@@ -54,7 +56,7 @@ class TrayNetwork : public SystemTrayItem, |
virtual void UpdateAfterShelfAlignmentChange( |
ShelfAlignment alignment) OVERRIDE; |
- // Overridden from NetworkObserver. |
+ // NetworkObserver |
virtual void OnNetworkRefresh(const NetworkIconInfo& info) OVERRIDE; |
virtual void SetNetworkMessage(NetworkTrayDelegate* delegate, |
MessageType message_type, |
@@ -65,27 +67,16 @@ class TrayNetwork : public SystemTrayItem, |
virtual void ClearNetworkMessage(MessageType message_type) OVERRIDE; |
virtual void OnWillToggleWifi() OVERRIDE; |
- // Called when the network for the tray icon may have been updated. |
- void TrayNetworkUpdated(); |
- |
- // Called when the properties for |network| may have been updated. |
- void NetworkServiceChanged(const chromeos::NetworkState* network); |
- |
- // Request a network connection (called from detailed view). |
- void ConnectToNetwork(const std::string& service_path); |
- |
- // Returns true if a user initiated connection to |network| occured. |
- bool HasConnectingNetwork(const std::string& service_path); |
+ // TrayNetworkStateObserver::Delegate |
+ virtual void NetworkStateChanged(bool list_changed) OVERRIDE; |
+ virtual void NetworkServiceChanged( |
+ const chromeos::NetworkState* network) OVERRIDE; |
// Gets the correct icon and label for |icon_type|. |
void GetNetworkStateHandlerImageAndLabel(network_icon::IconType icon_type, |
gfx::ImageSkia* image, |
string16* label); |
- // Updates and returns the appropriate message id if a network technology |
- // (i.e. cellular) is uninitialized. |
- int GetUninitializedMsg(); |
- |
private: |
friend class tray::NetworkMessageView; |
friend class tray::NetworkNotificationView; |
@@ -101,9 +92,6 @@ private: |
scoped_ptr<tray::NetworkMessages> messages_; |
bool request_wifi_view_; |
scoped_ptr<TrayNetworkStateObserver> network_state_observer_; |
- std::set<std::string> connecting_networks_; |
- base::Time uninitialized_state_time_; |
- int uninitialized_msg_; |
DISALLOW_COPY_AND_ASSIGN(TrayNetwork); |
}; |