| 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_OPTIONS2_BROWSER_OPTIONS_HANDLER2_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_OPTIONS2_BROWSER_OPTIONS_HANDLER2_H_ |
| 6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS2_BROWSER_OPTIONS_HANDLER2_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS2_BROWSER_OPTIONS_HANDLER2_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 118 // Gets the current default browser state, and asynchronously reports it to | 118 // Gets the current default browser state, and asynchronously reports it to |
| 119 // the WebUI page. | 119 // the WebUI page. |
| 120 void UpdateDefaultBrowserState(); | 120 void UpdateDefaultBrowserState(); |
| 121 | 121 |
| 122 // Updates the UI with the given state for the default browser. | 122 // Updates the UI with the given state for the default browser. |
| 123 void SetDefaultBrowserUIString(int status_string_id); | 123 void SetDefaultBrowserUIString(int status_string_id); |
| 124 | 124 |
| 125 // Loads the possible default search engine list and reports it to the WebUI. | 125 // Loads the possible default search engine list and reports it to the WebUI. |
| 126 void AddTemplateUrlServiceObserver(); | 126 void AddTemplateUrlServiceObserver(); |
| 127 | 127 |
| 128 // Sends an array of Profile objects to javascript. | 128 // Creates a list of dictionaries where each dictionary is of the form: |
| 129 // Each object is of the form: | |
| 130 // profileInfo = { | 129 // profileInfo = { |
| 131 // name: "Profile Name", | 130 // name: "Profile Name", |
| 132 // iconURL: "chrome://path/to/icon/image", | 131 // iconURL: "chrome://path/to/icon/image", |
| 133 // filePath: "/path/to/profile/data/on/disk", | 132 // filePath: "/path/to/profile/data/on/disk", |
| 134 // isCurrentProfile: false | 133 // isCurrentProfile: false |
| 135 // }; | 134 // }; |
| 135 scoped_ptr<ListValue> GetProfilesInfoList(); |
| 136 |
| 137 // Sends an array of Profile objects to javascript. |
| 136 void SendProfilesInfo(); | 138 void SendProfilesInfo(); |
| 137 | 139 |
| 138 // Asynchronously opens a new browser window to create a new profile. | 140 // Asynchronously opens a new browser window to create a new profile. |
| 139 // |args| is not used. | 141 // |args| is not used. |
| 140 void CreateProfile(const base::ListValue* args); | 142 void CreateProfile(const base::ListValue* args); |
| 141 | 143 |
| 142 void ObserveThemeChanged(); | 144 void ObserveThemeChanged(); |
| 143 void ThemesReset(const base::ListValue* args); | 145 void ThemesReset(const base::ListValue* args); |
| 144 #if defined(TOOLKIT_GTK) | 146 #if defined(TOOLKIT_GTK) |
| 145 void ThemesSetGTK(const base::ListValue* args); | 147 void ThemesSetGTK(const base::ListValue* args); |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 264 // Setup the checked state for SSL related checkboxes. | 266 // Setup the checked state for SSL related checkboxes. |
| 265 void SetupSSLConfigSettings(); | 267 void SetupSSLConfigSettings(); |
| 266 | 268 |
| 267 #if defined(OS_CHROMEOS) | 269 #if defined(OS_CHROMEOS) |
| 268 // Setup the accessibility features for ChromeOS. | 270 // Setup the accessibility features for ChromeOS. |
| 269 void SetupAccessibilityFeatures(); | 271 void SetupAccessibilityFeatures(); |
| 270 #endif | 272 #endif |
| 271 | 273 |
| 272 // Returns a newly created dictionary with a number of properties that | 274 // Returns a newly created dictionary with a number of properties that |
| 273 // correspond to the status of sync. | 275 // correspond to the status of sync. |
| 274 DictionaryValue* GetSyncStateDictionary(); | 276 scoped_ptr<DictionaryValue> GetSyncStateDictionary(); |
| 275 | 277 |
| 276 scoped_refptr<ShellIntegration::DefaultBrowserWorker> default_browser_worker_; | 278 scoped_refptr<ShellIntegration::DefaultBrowserWorker> default_browser_worker_; |
| 277 | 279 |
| 278 StringPrefMember homepage_; | 280 StringPrefMember homepage_; |
| 279 BooleanPrefMember default_browser_policy_; | 281 BooleanPrefMember default_browser_policy_; |
| 280 | 282 |
| 281 TemplateURLService* template_url_service_; // Weak. | 283 TemplateURLService* template_url_service_; // Weak. |
| 282 | 284 |
| 283 // Used to get |weak_ptr_| to self for use on the File thread. | 285 // Used to get |weak_ptr_| to self for use on the File thread. |
| 284 base::WeakPtrFactory<BrowserOptionsHandler> weak_ptr_factory_for_file_; | 286 base::WeakPtrFactory<BrowserOptionsHandler> weak_ptr_factory_for_file_; |
| (...skipping 27 matching lines...) Expand all Loading... |
| 312 #if !defined(OS_CHROMEOS) | 314 #if !defined(OS_CHROMEOS) |
| 313 scoped_ptr<PrefSetObserver> proxy_prefs_; | 315 scoped_ptr<PrefSetObserver> proxy_prefs_; |
| 314 #endif // !defined(OS_CHROMEOS) | 316 #endif // !defined(OS_CHROMEOS) |
| 315 | 317 |
| 316 DISALLOW_COPY_AND_ASSIGN(BrowserOptionsHandler); | 318 DISALLOW_COPY_AND_ASSIGN(BrowserOptionsHandler); |
| 317 }; | 319 }; |
| 318 | 320 |
| 319 } // namespace options2 | 321 } // namespace options2 |
| 320 | 322 |
| 321 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS2_BROWSER_OPTIONS_HANDLER2_H_ | 323 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS2_BROWSER_OPTIONS_HANDLER2_H_ |
| OLD | NEW |