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_COMMON_SYSTEM_TRAY_SYSTEM_TRAY_DELEGATE_H_ | 5 #ifndef ASH_COMMON_SYSTEM_TRAY_SYSTEM_TRAY_DELEGATE_H_ |
6 #define ASH_COMMON_SYSTEM_TRAY_SYSTEM_TRAY_DELEGATE_H_ | 6 #define ASH_COMMON_SYSTEM_TRAY_SYSTEM_TRAY_DELEGATE_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
118 | 118 |
119 // Returns NetworkingConfigDelegate. May return nullptr. | 119 // Returns NetworkingConfigDelegate. May return nullptr. |
120 virtual NetworkingConfigDelegate* GetNetworkingConfigDelegate() const; | 120 virtual NetworkingConfigDelegate* GetNetworkingConfigDelegate() const; |
121 | 121 |
122 // Retrieves the session start time. Returns |false| if the time is not set. | 122 // Retrieves the session start time. Returns |false| if the time is not set. |
123 virtual bool GetSessionStartTime(base::TimeTicks* session_start_time); | 123 virtual bool GetSessionStartTime(base::TimeTicks* session_start_time); |
124 | 124 |
125 // Retrieves the session length limit. Returns |false| if no limit is set. | 125 // Retrieves the session length limit. Returns |false| if no limit is set. |
126 virtual bool GetSessionLengthLimit(base::TimeDelta* session_length_limit); | 126 virtual bool GetSessionLengthLimit(base::TimeDelta* session_length_limit); |
127 | 127 |
128 // Get the system tray menu size in pixels (dependent on the language). | |
129 // This is not used in material design and should be removed during pre-MD | |
130 // code cleanup. See https://crbug.com/614453. | |
131 virtual int GetSystemTrayMenuWidth(); | |
132 | |
133 // The active user has been changed. This will be called when the UI is ready | 128 // The active user has been changed. This will be called when the UI is ready |
134 // to be switched to the new user. | 129 // to be switched to the new user. |
135 // Note: This will happen after SessionStateObserver::ActiveUserChanged fires. | 130 // Note: This will happen after SessionStateObserver::ActiveUserChanged fires. |
136 virtual void ActiveUserWasChanged(); | 131 virtual void ActiveUserWasChanged(); |
137 | 132 |
138 // Returns true when the Search key is configured to be treated as Caps Lock. | 133 // Returns true when the Search key is configured to be treated as Caps Lock. |
139 virtual bool IsSearchKeyMappedToCapsLock(); | 134 virtual bool IsSearchKeyMappedToCapsLock(); |
140 | 135 |
141 // Adding observers that are notified when supervised info is being changed. | 136 // Adding observers that are notified when supervised info is being changed. |
142 virtual void AddCustodianInfoTrayObserver( | 137 virtual void AddCustodianInfoTrayObserver( |
143 CustodianInfoTrayObserver* observer); | 138 CustodianInfoTrayObserver* observer); |
144 | 139 |
145 virtual void RemoveCustodianInfoTrayObserver( | 140 virtual void RemoveCustodianInfoTrayObserver( |
146 CustodianInfoTrayObserver* observer); | 141 CustodianInfoTrayObserver* observer); |
147 | 142 |
148 // Creates a system tray item for display rotation lock. | 143 // Creates a system tray item for display rotation lock. |
149 // TODO(jamescook): Remove this when mus has support for display management | 144 // TODO(jamescook): Remove this when mus has support for display management |
150 // and we have a DisplayManager equivalent. See http://crbug.com/548429 | 145 // and we have a DisplayManager equivalent. See http://crbug.com/548429 |
151 virtual std::unique_ptr<SystemTrayItem> CreateRotationLockTrayItem( | 146 virtual std::unique_ptr<SystemTrayItem> CreateRotationLockTrayItem( |
152 SystemTray* tray); | 147 SystemTray* tray); |
153 }; | 148 }; |
154 | 149 |
155 } // namespace ash | 150 } // namespace ash |
156 | 151 |
157 #endif // ASH_COMMON_SYSTEM_TRAY_SYSTEM_TRAY_DELEGATE_H_ | 152 #endif // ASH_COMMON_SYSTEM_TRAY_SYSTEM_TRAY_DELEGATE_H_ |
OLD | NEW |