OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_NETWORK_NETWORK_DETAILED_VIEW_H | 5 #ifndef ASH_SYSTEM_CHROMEOS_NETWORK_NETWORK_DETAILED_VIEW_H |
6 #define ASH_SYSTEM_CHROMEOS_NETWORK_NETWORK_DETAILED_VIEW_H | 6 #define ASH_SYSTEM_CHROMEOS_NETWORK_NETWORK_DETAILED_VIEW_H |
7 | 7 |
8 #include "ash/common/system/tray/tray_details_view.h" | 8 #include "ash/common/system/tray/tray_details_view.h" |
9 #include "chromeos/network/network_state_handler.h" | 9 #include "chromeos/network/network_state_handler.h" |
10 | 10 |
11 namespace ash { | 11 namespace ash { |
12 namespace tray { | 12 namespace tray { |
13 | 13 |
14 // Abstract base class for all NetworkDetailedView derived subclasses, | 14 // Abstract base class for all NetworkDetailedView derived subclasses, |
15 // which includes NetworkWifiDetailedView and NetworkStateListDetailedView. | 15 // which includes NetworkWifiDetailedView and NetworkStateListDetailedView. |
16 class NetworkDetailedView : public TrayDetailsView { | 16 class NetworkDetailedView : public TrayDetailsView { |
17 public: | 17 public: |
18 enum DetailedViewType { | 18 enum DetailedViewType { |
19 LIST_VIEW, | 19 LIST_VIEW, |
20 STATE_LIST_VIEW, | 20 STATE_LIST_VIEW, |
21 WIFI_VIEW, | 21 WIFI_VIEW, |
22 }; | 22 }; |
23 | 23 |
24 explicit NetworkDetailedView(SystemTrayItem* owner) | 24 explicit NetworkDetailedView(SystemTrayItem* owner) |
25 : TrayDetailsView(owner) { | 25 : TrayDetailsView(owner) {} |
26 } | |
27 | 26 |
28 virtual void Init() = 0; | 27 virtual void Init() = 0; |
29 | 28 |
30 virtual DetailedViewType GetViewType() const = 0; | 29 virtual DetailedViewType GetViewType() const = 0; |
31 | 30 |
32 // Called when the contents of the network list have changed or when any | 31 // Called when the contents of the network list have changed or when any |
33 // Manager properties (e.g. technology state) have changed. | 32 // Manager properties (e.g. technology state) have changed. |
34 // (Called only from TrayNetworkStateObserver). | 33 // (Called only from TrayNetworkStateObserver). |
35 virtual void Update() = 0; | 34 virtual void Update() = 0; |
36 | 35 |
37 protected: | 36 protected: |
38 ~NetworkDetailedView() override {} | 37 ~NetworkDetailedView() override {} |
39 }; | 38 }; |
40 | 39 |
41 } // namespace tray | 40 } // namespace tray |
42 } // namespace ash | 41 } // namespace ash |
43 | 42 |
44 #endif // ASH_SYSTEM_CHROMEOS_NETWORK_NETWORK_DETAILED_VIEW_H | 43 #endif // ASH_SYSTEM_CHROMEOS_NETWORK_NETWORK_DETAILED_VIEW_H |
OLD | NEW |