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_SHELL_DELEGATE_H_ | 5 #ifndef ASH_SHELL_DELEGATE_H_ |
6 #define ASH_SHELL_DELEGATE_H_ | 6 #define ASH_SHELL_DELEGATE_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "ash/ash_export.h" | 11 #include "ash/ash_export.h" |
12 #include "base/callback.h" | 12 #include "base/callback.h" |
13 #include "base/strings/string16.h" | 13 #include "base/strings/string16.h" |
14 | 14 |
15 class GURL; | 15 class GURL; |
| 16 class PrefService; |
16 | 17 |
17 namespace gfx { | 18 namespace gfx { |
18 class Image; | 19 class Image; |
19 } | 20 } |
20 | 21 |
21 namespace keyboard { | 22 namespace keyboard { |
22 class KeyboardUI; | 23 class KeyboardUI; |
23 } | 24 } |
24 | 25 |
25 namespace service_manager { | 26 namespace service_manager { |
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
114 // Creates a GPU support object. Shell takes ownership of the object. | 115 // Creates a GPU support object. Shell takes ownership of the object. |
115 virtual GPUSupport* CreateGPUSupport() = 0; | 116 virtual GPUSupport* CreateGPUSupport() = 0; |
116 | 117 |
117 // Get the product name. | 118 // Get the product name. |
118 virtual base::string16 GetProductName() const = 0; | 119 virtual base::string16 GetProductName() const = 0; |
119 | 120 |
120 virtual void OpenKeyboardShortcutHelpPage() const {} | 121 virtual void OpenKeyboardShortcutHelpPage() const {} |
121 | 122 |
122 virtual gfx::Image GetDeprecatedAcceleratorImage() const = 0; | 123 virtual gfx::Image GetDeprecatedAcceleratorImage() const = 0; |
123 | 124 |
| 125 virtual PrefService* GetActiveUserPrefService() const = 0; |
| 126 |
124 // If |use_local_state| is true, returns the touchscreen status from local | 127 // If |use_local_state| is true, returns the touchscreen status from local |
125 // state, otherwise from user prefs. | 128 // state, otherwise from user prefs. |
126 virtual bool IsTouchscreenEnabledInPrefs(bool use_local_state) const = 0; | 129 virtual bool IsTouchscreenEnabledInPrefs(bool use_local_state) const = 0; |
127 | 130 |
128 // Sets the status of touchscreen to |enabled| in prefs. If |use_local_state|, | 131 // Sets the status of touchscreen to |enabled| in prefs. If |use_local_state|, |
129 // pref is set in local state, otherwise in user prefs. | 132 // pref is set in local state, otherwise in user prefs. |
130 virtual void SetTouchscreenEnabledInPrefs(bool enabled, | 133 virtual void SetTouchscreenEnabledInPrefs(bool enabled, |
131 bool use_local_state) = 0; | 134 bool use_local_state) = 0; |
132 | 135 |
133 // Updates the enabled/disabled status of the touchscreen from prefs. Enabled | 136 // Updates the enabled/disabled status of the touchscreen from prefs. Enabled |
134 // if both local state and user prefs are enabled, otherwise disabled. | 137 // if both local state and user prefs are enabled, otherwise disabled. |
135 virtual void UpdateTouchscreenStatusFromPrefs() = 0; | 138 virtual void UpdateTouchscreenStatusFromPrefs() = 0; |
136 | 139 |
137 // Toggles the status of touchpad between enabled and disabled. | 140 // Toggles the status of touchpad between enabled and disabled. |
138 virtual void ToggleTouchpad() {} | 141 virtual void ToggleTouchpad() {} |
139 }; | 142 }; |
140 | 143 |
141 } // namespace ash | 144 } // namespace ash |
142 | 145 |
143 #endif // ASH_SHELL_DELEGATE_H_ | 146 #endif // ASH_SHELL_DELEGATE_H_ |
OLD | NEW |