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 CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_CORE_CHROMEOS_OPTIONS_HANDLER_H _ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_CORE_CHROMEOS_OPTIONS_HANDLER_H _ |
6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_CORE_CHROMEOS_OPTIONS_HANDLER_H _ | 6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_CORE_CHROMEOS_OPTIONS_HANDLER_H _ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
jdoerrie
2017/04/13 09:08:52
#include <memory>
vabr (Chromium)
2017/04/13 12:03:14
Done.
| |
10 | 10 |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "base/memory/linked_ptr.h" | 12 #include "base/memory/linked_ptr.h" |
13 #include "chrome/browser/chromeos/settings/cros_settings.h" | 13 #include "chrome/browser/chromeos/settings/cros_settings.h" |
14 #include "chrome/browser/ui/webui/options/core_options_handler.h" | 14 #include "chrome/browser/ui/webui/options/core_options_handler.h" |
15 #include "content/public/browser/notification_observer.h" | 15 #include "content/public/browser/notification_observer.h" |
16 #include "content/public/browser/notification_registrar.h" | 16 #include "content/public/browser/notification_registrar.h" |
17 | 17 |
18 namespace chromeos { | 18 namespace chromeos { |
19 namespace options { | 19 namespace options { |
20 | 20 |
21 // CoreChromeOSOptionsHandler handles ChromeOS settings. | 21 // CoreChromeOSOptionsHandler handles ChromeOS settings. |
22 class CoreChromeOSOptionsHandler : public ::options::CoreOptionsHandler, | 22 class CoreChromeOSOptionsHandler : public ::options::CoreOptionsHandler, |
23 public content::NotificationObserver { | 23 public content::NotificationObserver { |
24 public: | 24 public: |
25 CoreChromeOSOptionsHandler(); | 25 CoreChromeOSOptionsHandler(); |
26 ~CoreChromeOSOptionsHandler() override; | 26 ~CoreChromeOSOptionsHandler() override; |
27 | 27 |
28 // ::CoreOptionsHandler overrides | 28 // ::CoreOptionsHandler overrides |
29 void RegisterMessages() override; | 29 void RegisterMessages() override; |
30 base::Value* FetchPref(const std::string& pref_name) override; | 30 std::unique_ptr<base::Value> FetchPref(const std::string& pref_name) override; |
31 void InitializeHandler() override; | 31 void InitializeHandler() override; |
32 void ObservePref(const std::string& pref_name) override; | 32 void ObservePref(const std::string& pref_name) override; |
33 void SetPref(const std::string& pref_name, | 33 void SetPref(const std::string& pref_name, |
34 const base::Value* value, | 34 const base::Value* value, |
35 const std::string& metric) override; | 35 const std::string& metric) override; |
36 void StopObservingPref(const std::string& path) override; | 36 void StopObservingPref(const std::string& path) override; |
37 base::Value* CreateValueForPref( | 37 std::unique_ptr<base::Value> CreateValueForPref( |
38 const std::string& pref_name, | 38 const std::string& pref_name, |
39 const std::string& controlling_pref_name) override; | 39 const std::string& controlling_pref_name) override; |
40 | 40 |
41 // OptionsPageUIHandler implementation. | 41 // OptionsPageUIHandler implementation. |
42 void GetLocalizedValues(base::DictionaryValue* localized_strings) override; | 42 void GetLocalizedValues(base::DictionaryValue* localized_strings) override; |
43 | 43 |
44 // content::NotificationObserver implementation. | 44 // content::NotificationObserver implementation. |
45 void Observe(int type, | 45 void Observe(int type, |
46 const content::NotificationSource& source, | 46 const content::NotificationSource& source, |
47 const content::NotificationDetails& details) override; | 47 const content::NotificationDetails& details) override; |
(...skipping 23 matching lines...) Expand all Loading... | |
71 // Currently selected network id. | 71 // Currently selected network id. |
72 std::string network_guid_; | 72 std::string network_guid_; |
73 | 73 |
74 DISALLOW_COPY_AND_ASSIGN(CoreChromeOSOptionsHandler); | 74 DISALLOW_COPY_AND_ASSIGN(CoreChromeOSOptionsHandler); |
75 }; | 75 }; |
76 | 76 |
77 } // namespace options | 77 } // namespace options |
78 } // namespace chromeos | 78 } // namespace chromeos |
79 | 79 |
80 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_CORE_CHROMEOS_OPTIONS_HANDLE R_H_ | 80 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_CORE_CHROMEOS_OPTIONS_HANDLE R_H_ |
OLD | NEW |