OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #include "chrome/browser/prefs/browser_prefs.h" | 5 #include "chrome/browser/prefs/browser_prefs.h" |
6 | 6 |
7 #include "apps/prefs.h" | 7 #include "apps/prefs.h" |
8 #include "base/prefs/pref_registry_simple.h" | 8 #include "base/prefs/pref_registry_simple.h" |
9 #include "base/prefs/pref_service.h" | 9 #include "base/prefs/pref_service.h" |
10 #include "chrome/browser/about_flags.h" | 10 #include "chrome/browser/about_flags.h" |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
62 #include "chrome/browser/profiles/profile_info_cache.h" | 62 #include "chrome/browser/profiles/profile_info_cache.h" |
63 #include "chrome/browser/profiles/profile_manager.h" | 63 #include "chrome/browser/profiles/profile_manager.h" |
64 #include "chrome/browser/renderer_host/web_cache_manager.h" | 64 #include "chrome/browser/renderer_host/web_cache_manager.h" |
65 #include "chrome/browser/search_engines/template_url_prepopulate_data.h" | 65 #include "chrome/browser/search_engines/template_url_prepopulate_data.h" |
66 #include "chrome/browser/signin/signin_manager_factory.h" | 66 #include "chrome/browser/signin/signin_manager_factory.h" |
67 #include "chrome/browser/sync/invalidations/invalidator_storage.h" | 67 #include "chrome/browser/sync/invalidations/invalidator_storage.h" |
68 #include "chrome/browser/sync/sync_prefs.h" | 68 #include "chrome/browser/sync/sync_prefs.h" |
69 #include "chrome/browser/task_manager/task_manager.h" | 69 #include "chrome/browser/task_manager/task_manager.h" |
70 #include "chrome/browser/translate/translate_prefs.h" | 70 #include "chrome/browser/translate/translate_prefs.h" |
71 #include "chrome/browser/ui/alternate_error_tab_observer.h" | 71 #include "chrome/browser/ui/alternate_error_tab_observer.h" |
72 #include "chrome/browser/ui/app_list/app_list_util.h" | 72 #include "chrome/browser/ui/app_list/app_list_service.h" |
73 #include "chrome/browser/ui/autofill/autofill_dialog_controller_impl.h" | 73 #include "chrome/browser/ui/autofill/autofill_dialog_controller_impl.h" |
74 #include "chrome/browser/ui/browser_instant_controller.h" | 74 #include "chrome/browser/ui/browser_instant_controller.h" |
75 #include "chrome/browser/ui/browser_ui_prefs.h" | 75 #include "chrome/browser/ui/browser_ui_prefs.h" |
76 #include "chrome/browser/ui/network_profile_bubble.h" | 76 #include "chrome/browser/ui/network_profile_bubble.h" |
77 #include "chrome/browser/ui/prefs/prefs_tab_helper.h" | 77 #include "chrome/browser/ui/prefs/prefs_tab_helper.h" |
78 #include "chrome/browser/ui/search_engines/keyword_editor_controller.h" | 78 #include "chrome/browser/ui/search_engines/keyword_editor_controller.h" |
79 #include "chrome/browser/ui/startup/autolaunch_prompt.h" | 79 #include "chrome/browser/ui/startup/autolaunch_prompt.h" |
80 #include "chrome/browser/ui/tabs/pinned_tab_codec.h" | 80 #include "chrome/browser/ui/tabs/pinned_tab_codec.h" |
81 #include "chrome/browser/ui/webui/extensions/extension_settings_handler.h" | 81 #include "chrome/browser/ui/webui/extensions/extension_settings_handler.h" |
82 #include "chrome/browser/ui/webui/flags_ui.h" | 82 #include "chrome/browser/ui/webui/flags_ui.h" |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
166 | 166 |
167 } // namespace | 167 } // namespace |
168 | 168 |
169 namespace chrome { | 169 namespace chrome { |
170 | 170 |
171 void RegisterLocalState(PrefRegistrySimple* registry) { | 171 void RegisterLocalState(PrefRegistrySimple* registry) { |
172 // Prefs in Local State. | 172 // Prefs in Local State. |
173 registry->RegisterIntegerPref(prefs::kMultipleProfilePrefMigration, 0); | 173 registry->RegisterIntegerPref(prefs::kMultipleProfilePrefMigration, 0); |
174 | 174 |
175 // Please keep this list alphabetized. | 175 // Please keep this list alphabetized. |
| 176 AppListService::RegisterPrefs(registry); |
176 apps::RegisterPrefs(registry); | 177 apps::RegisterPrefs(registry); |
177 browser_shutdown::RegisterPrefs(registry); | 178 browser_shutdown::RegisterPrefs(registry); |
178 BrowserProcessImpl::RegisterPrefs(registry); | 179 BrowserProcessImpl::RegisterPrefs(registry); |
179 chrome::RegisterScreenshotPrefs(registry); | 180 chrome::RegisterScreenshotPrefs(registry); |
180 ExternalProtocolHandler::RegisterPrefs(registry); | 181 ExternalProtocolHandler::RegisterPrefs(registry); |
181 FlagsUI::RegisterPrefs(registry); | 182 FlagsUI::RegisterPrefs(registry); |
182 geolocation::RegisterPrefs(registry); | 183 geolocation::RegisterPrefs(registry); |
183 GLStringManager::RegisterPrefs(registry); | 184 GLStringManager::RegisterPrefs(registry); |
184 IntranetRedirectDetector::RegisterPrefs(registry); | 185 IntranetRedirectDetector::RegisterPrefs(registry); |
185 IOThread::RegisterPrefs(registry); | 186 IOThread::RegisterPrefs(registry); |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
244 chromeos::UserManager::RegisterPrefs(registry); | 245 chromeos::UserManager::RegisterPrefs(registry); |
245 chromeos::WallpaperManager::RegisterPrefs(registry); | 246 chromeos::WallpaperManager::RegisterPrefs(registry); |
246 chromeos::WizardController::RegisterPrefs(registry); | 247 chromeos::WizardController::RegisterPrefs(registry); |
247 policy::AutoEnrollmentClient::RegisterPrefs(registry); | 248 policy::AutoEnrollmentClient::RegisterPrefs(registry); |
248 policy::DeviceStatusCollector::RegisterPrefs(registry); | 249 policy::DeviceStatusCollector::RegisterPrefs(registry); |
249 #endif | 250 #endif |
250 | 251 |
251 #if defined(OS_MACOSX) | 252 #if defined(OS_MACOSX) |
252 confirm_quit::RegisterLocalState(registry); | 253 confirm_quit::RegisterLocalState(registry); |
253 #endif | 254 #endif |
254 | |
255 #if defined(ENABLE_SETTINGS_APP) | |
256 chrome::RegisterAppListPrefs(registry); | |
257 #endif | |
258 } | 255 } |
259 | 256 |
260 void RegisterUserPrefs(PrefService* user_prefs, | 257 void RegisterUserPrefs(PrefService* user_prefs, |
261 PrefRegistrySyncable* registry) { | 258 PrefRegistrySyncable* registry) { |
262 // TODO(joi): Get rid of the need for the PrefService parameter, and | 259 // TODO(joi): Get rid of the need for the PrefService parameter, and |
263 // do registration prior to PrefService creation. | 260 // do registration prior to PrefService creation. |
264 | 261 |
265 // User prefs. Please keep this list alphabetized. | 262 // User prefs. Please keep this list alphabetized. |
266 AlternateErrorPageTabObserver::RegisterUserPrefs(registry); | 263 AlternateErrorPageTabObserver::RegisterUserPrefs(registry); |
267 autofill::AutofillDialogControllerImpl::RegisterUserPrefs(registry); | 264 autofill::AutofillDialogControllerImpl::RegisterUserPrefs(registry); |
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
437 } | 434 } |
438 local_state->ClearPref(prefs::kLastPromptedGoogleURL); | 435 local_state->ClearPref(prefs::kLastPromptedGoogleURL); |
439 | 436 |
440 current_version |= GOOGLE_URL_TRACKER_PREFS; | 437 current_version |= GOOGLE_URL_TRACKER_PREFS; |
441 local_state->SetInteger(prefs::kMultipleProfilePrefMigration, | 438 local_state->SetInteger(prefs::kMultipleProfilePrefMigration, |
442 current_version); | 439 current_version); |
443 } | 440 } |
444 } | 441 } |
445 | 442 |
446 } // namespace chrome | 443 } // namespace chrome |
OLD | NEW |