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_TRAY_SYSTEM_TRAY_DELEGATE_H_ | 5 #ifndef ASH_SYSTEM_TRAY_SYSTEM_TRAY_DELEGATE_H_ |
6 #define ASH_SYSTEM_TRAY_SYSTEM_TRAY_DELEGATE_H_ | 6 #define ASH_SYSTEM_TRAY_SYSTEM_TRAY_DELEGATE_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 12 matching lines...) Expand all Loading... |
23 NetworkIconInfo(); | 23 NetworkIconInfo(); |
24 ~NetworkIconInfo(); | 24 ~NetworkIconInfo(); |
25 | 25 |
26 bool highlight; | 26 bool highlight; |
27 SkBitmap image; | 27 SkBitmap image; |
28 string16 name; | 28 string16 name; |
29 string16 description; | 29 string16 description; |
30 std::string service_path; | 30 std::string service_path; |
31 }; | 31 }; |
32 | 32 |
| 33 struct ASH_EXPORT BluetoothDeviceInfo { |
| 34 BluetoothDeviceInfo(); |
| 35 ~BluetoothDeviceInfo(); |
| 36 |
| 37 std::string address; |
| 38 string16 display_name; |
| 39 bool connected; |
| 40 }; |
| 41 |
| 42 typedef std::vector<BluetoothDeviceInfo> BluetoothDeviceList; |
| 43 |
33 struct ASH_EXPORT IMEInfo { | 44 struct ASH_EXPORT IMEInfo { |
34 IMEInfo(); | 45 IMEInfo(); |
35 ~IMEInfo(); | 46 ~IMEInfo(); |
36 | 47 |
37 bool selected; | 48 bool selected; |
38 std::string id; | 49 std::string id; |
39 string16 name; | 50 string16 name; |
40 string16 short_name; | 51 string16 short_name; |
41 }; | 52 }; |
42 | 53 |
(...skipping 22 matching lines...) Expand all Loading... |
65 | 76 |
66 // Gets the current power supply status. | 77 // Gets the current power supply status. |
67 virtual PowerSupplyStatus GetPowerSupplyStatus() const = 0; | 78 virtual PowerSupplyStatus GetPowerSupplyStatus() const = 0; |
68 | 79 |
69 // Shows settings. | 80 // Shows settings. |
70 virtual void ShowSettings() = 0; | 81 virtual void ShowSettings() = 0; |
71 | 82 |
72 // Shows the settings related to date, timezone etc. | 83 // Shows the settings related to date, timezone etc. |
73 virtual void ShowDateSettings() = 0; | 84 virtual void ShowDateSettings() = 0; |
74 | 85 |
75 // Show the settings related to network. | 86 // Shows the settings related to network. |
76 virtual void ShowNetworkSettings() = 0; | 87 virtual void ShowNetworkSettings() = 0; |
77 | 88 |
| 89 // Shows the settings related to bluetooth. |
| 90 virtual void ShowBluetoothSettings() = 0; |
| 91 |
78 // Shows help. | 92 // Shows help. |
79 virtual void ShowHelp() = 0; | 93 virtual void ShowHelp() = 0; |
80 | 94 |
81 // Is the system audio muted? | 95 // Is the system audio muted? |
82 virtual bool IsAudioMuted() const = 0; | 96 virtual bool IsAudioMuted() const = 0; |
83 | 97 |
84 // Mutes/Unmutes the audio system. | 98 // Mutes/Unmutes the audio system. |
85 virtual void SetAudioMuted(bool muted) = 0; | 99 virtual void SetAudioMuted(bool muted) = 0; |
86 | 100 |
87 // Gets the volume level. | 101 // Gets the volume level. |
(...skipping 10 matching lines...) Expand all Loading... |
98 | 112 |
99 // Attempts to shut down the system. | 113 // Attempts to shut down the system. |
100 virtual void ShutDown() = 0; | 114 virtual void ShutDown() = 0; |
101 | 115 |
102 // Attempts to sign out the user. | 116 // Attempts to sign out the user. |
103 virtual void SignOut() = 0; | 117 virtual void SignOut() = 0; |
104 | 118 |
105 // Attempts to lock the screen. | 119 // Attempts to lock the screen. |
106 virtual void RequestLockScreen() = 0; | 120 virtual void RequestLockScreen() = 0; |
107 | 121 |
| 122 // Returns a list of available bluetooth devices. |
| 123 virtual void GetAvailableBluetoothDevices(BluetoothDeviceList* devices) = 0; |
| 124 |
108 // Returns a list of availble IMEs. | 125 // Returns a list of availble IMEs. |
109 virtual IMEInfoList GetAvailableIMEList() = 0; | 126 virtual void GetAvailableIMEList(IMEInfoList* list) = 0; |
110 | 127 |
111 // Returns information about the most relevant network. Relevance is | 128 // Returns information about the most relevant network. Relevance is |
112 // determined by the implementor (e.g. a connecting network may be more | 129 // determined by the implementor (e.g. a connecting network may be more |
113 // relevant over a connected network etc.) | 130 // relevant over a connected network etc.) |
114 virtual NetworkIconInfo GetMostRelevantNetworkIcon(bool large) = 0; | 131 virtual NetworkIconInfo GetMostRelevantNetworkIcon(bool large) = 0; |
115 | 132 |
116 // Returns information about the available networks. | 133 // Returns information about the available networks. |
117 virtual void GetAvailableNetworks(std::vector<NetworkIconInfo>* list) = 0; | 134 virtual void GetAvailableNetworks(std::vector<NetworkIconInfo>* list) = 0; |
118 | 135 |
119 // Connects to the network specified by the unique id. | 136 // Connects to the network specified by the unique id. |
120 virtual void ConnectToNetwork(const std::string& network_id) = 0; | 137 virtual void ConnectToNetwork(const std::string& network_id) = 0; |
121 | 138 |
| 139 // Shous UI to add a new bluetooth device. |
| 140 virtual void AddBluetoothDevice() = 0; |
| 141 |
122 // Toggles airplane mode. | 142 // Toggles airplane mode. |
123 virtual void ToggleAirplaneMode() = 0; | 143 virtual void ToggleAirplaneMode() = 0; |
124 | 144 |
125 // Toggles wifi network. | 145 // Toggles wifi network. |
126 virtual void ToggleWifi() = 0; | 146 virtual void ToggleWifi() = 0; |
127 | 147 |
128 // Toggles cellular network. | 148 // Toggles cellular network. |
129 virtual void ToggleCellular() = 0; | 149 virtual void ToggleCellular() = 0; |
130 | 150 |
| 151 // Toggles bluetooth. |
| 152 virtual void ToggleBluetooth() = 0; |
| 153 |
131 // Returns whether wifi is available. | 154 // Returns whether wifi is available. |
132 virtual bool GetWifiAvailable() = 0; | 155 virtual bool GetWifiAvailable() = 0; |
133 | 156 |
134 // Returns whether cellular networking is available. | 157 // Returns whether cellular networking is available. |
135 virtual bool GetCellularAvailable() = 0; | 158 virtual bool GetCellularAvailable() = 0; |
136 | 159 |
| 160 // Returns whether bluetooth capability is available. |
| 161 virtual bool GetBluetoothAvailable() = 0; |
| 162 |
137 // Returns whether wifi is enabled. | 163 // Returns whether wifi is enabled. |
138 virtual bool GetWifiEnabled() = 0; | 164 virtual bool GetWifiEnabled() = 0; |
139 | 165 |
140 // Returns whether cellular networking is enabled. | 166 // Returns whether cellular networking is enabled. |
141 virtual bool GetCellularEnabled() = 0; | 167 virtual bool GetCellularEnabled() = 0; |
142 | 168 |
| 169 // Returns whether bluetooth is enabled. |
| 170 virtual bool GetBluetoothEnabled() = 0; |
| 171 |
143 // Shows UI for changing proxy settings. | 172 // Shows UI for changing proxy settings. |
144 virtual void ChangeProxySettings() = 0; | 173 virtual void ChangeProxySettings() = 0; |
145 }; | 174 }; |
146 | 175 |
147 } // namespace ash | 176 } // namespace ash |
148 | 177 |
149 #endif // ASH_SYSTEM_TRAY_SYSTEM_TRAY_DELEGATE_H_ | 178 #endif // ASH_SYSTEM_TRAY_SYSTEM_TRAY_DELEGATE_H_ |
OLD | NEW |