| 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/debug/trace_event.h" | 8 #include "base/debug/trace_event.h" |
| 9 #include "base/prefs/pref_registry_simple.h" | 9 #include "base/prefs/pref_registry_simple.h" |
| 10 #include "base/prefs/pref_service.h" | 10 #include "base/prefs/pref_service.h" |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 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/search.h" | 65 #include "chrome/browser/search/search.h" |
| 66 #include "chrome/browser/search_engines/template_url_prepopulate_data.h" | 66 #include "chrome/browser/search_engines/template_url_prepopulate_data.h" |
| 67 #include "chrome/browser/signin/signin_manager_factory.h" | 67 #include "chrome/browser/signin/signin_manager_factory.h" |
| 68 #include "chrome/browser/signin/signin_promo.h" | 68 #include "chrome/browser/signin/signin_promo.h" |
| 69 #include "chrome/browser/sync/sync_prefs.h" | 69 #include "chrome/browser/sync/sync_prefs.h" |
| 70 #include "chrome/browser/task_manager/task_manager.h" | 70 #include "chrome/browser/task_manager/task_manager.h" |
| 71 #include "chrome/browser/translate/translate_prefs.h" | 71 #include "chrome/browser/translate/translate_prefs.h" |
| 72 #include "chrome/browser/ui/alternate_error_tab_observer.h" | 72 #include "chrome/browser/ui/alternate_error_tab_observer.h" |
| 73 #include "chrome/browser/ui/app_list/app_list_service.h" | 73 #include "chrome/browser/ui/app_list/app_list_service.h" |
| 74 #include "chrome/browser/ui/autofill/autofill_credit_card_bubble_controller.h" | |
| 75 #include "chrome/browser/ui/browser_ui_prefs.h" | 74 #include "chrome/browser/ui/browser_ui_prefs.h" |
| 76 #include "chrome/browser/ui/network_profile_bubble.h" | 75 #include "chrome/browser/ui/network_profile_bubble.h" |
| 77 #include "chrome/browser/ui/prefs/prefs_tab_helper.h" | 76 #include "chrome/browser/ui/prefs/prefs_tab_helper.h" |
| 78 #include "chrome/browser/ui/search_engines/keyword_editor_controller.h" | 77 #include "chrome/browser/ui/search_engines/keyword_editor_controller.h" |
| 79 #include "chrome/browser/ui/startup/autolaunch_prompt.h" | 78 #include "chrome/browser/ui/startup/autolaunch_prompt.h" |
| 80 #include "chrome/browser/ui/startup/default_browser_prompt.h" | 79 #include "chrome/browser/ui/startup/default_browser_prompt.h" |
| 81 #include "chrome/browser/ui/tabs/pinned_tab_codec.h" | 80 #include "chrome/browser/ui/tabs/pinned_tab_codec.h" |
| 82 #include "chrome/browser/ui/webui/extensions/extension_settings_handler.h" | 81 #include "chrome/browser/ui/webui/extensions/extension_settings_handler.h" |
| 83 #include "chrome/browser/ui/webui/flags_ui.h" | 82 #include "chrome/browser/ui/webui/flags_ui.h" |
| 84 #include "chrome/browser/ui/webui/instant_ui.h" | 83 #include "chrome/browser/ui/webui/instant_ui.h" |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 149 #else | 148 #else |
| 150 #include "chrome/browser/extensions/default_apps.h" | 149 #include "chrome/browser/extensions/default_apps.h" |
| 151 #endif | 150 #endif |
| 152 | 151 |
| 153 #if defined(USE_ASH) | 152 #if defined(USE_ASH) |
| 154 #include "chrome/browser/ui/ash/chrome_launcher_prefs.h" | 153 #include "chrome/browser/ui/ash/chrome_launcher_prefs.h" |
| 155 #endif | 154 #endif |
| 156 | 155 |
| 157 #if defined(OS_ANDROID) | 156 #if defined(OS_ANDROID) |
| 158 #include "chrome/browser/ui/webui/ntp/android/promo_handler.h" | 157 #include "chrome/browser/ui/webui/ntp/android/promo_handler.h" |
| 158 #else |
| 159 #include "chrome/browser/ui/autofill/generated_credit_card_bubble_controller.h" |
| 159 #endif | 160 #endif |
| 160 | 161 |
| 161 #if defined(ENABLE_PLUGIN_INSTALLATION) | 162 #if defined(ENABLE_PLUGIN_INSTALLATION) |
| 162 #include "chrome/browser/plugins/plugins_resource_service.h" | 163 #include "chrome/browser/plugins/plugins_resource_service.h" |
| 163 #endif | 164 #endif |
| 164 | 165 |
| 165 namespace { | 166 namespace { |
| 166 | 167 |
| 167 enum MigratedPreferences { | 168 enum MigratedPreferences { |
| 168 NO_PREFS = 0, | 169 NO_PREFS = 0, |
| (...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 283 confirm_quit::RegisterLocalState(registry); | 284 confirm_quit::RegisterLocalState(registry); |
| 284 #endif | 285 #endif |
| 285 } | 286 } |
| 286 | 287 |
| 287 // Register prefs applicable to all profiles. | 288 // Register prefs applicable to all profiles. |
| 288 void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry) { | 289 void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry) { |
| 289 TRACE_EVENT0("browser", "chrome::RegisterUserPrefs"); | 290 TRACE_EVENT0("browser", "chrome::RegisterUserPrefs"); |
| 290 // User prefs. Please keep this list alphabetized. | 291 // User prefs. Please keep this list alphabetized. |
| 291 AlternateErrorPageTabObserver::RegisterProfilePrefs(registry); | 292 AlternateErrorPageTabObserver::RegisterProfilePrefs(registry); |
| 292 apps::RegisterProfilePrefs(registry); | 293 apps::RegisterProfilePrefs(registry); |
| 293 autofill::AutofillCreditCardBubbleController::RegisterUserPrefs(registry); | |
| 294 autofill::AutofillManager::RegisterProfilePrefs(registry); | 294 autofill::AutofillManager::RegisterProfilePrefs(registry); |
| 295 #if !defined(OS_ANDROID) |
| 296 autofill::GeneratedCreditCardBubbleController::RegisterUserPrefs(registry); |
| 297 #endif |
| 295 BookmarkPromptPrefs::RegisterProfilePrefs(registry); | 298 BookmarkPromptPrefs::RegisterProfilePrefs(registry); |
| 296 bookmark_utils::RegisterProfilePrefs(registry); | 299 bookmark_utils::RegisterProfilePrefs(registry); |
| 297 browser_sync::SyncPrefs::RegisterProfilePrefs(registry); | 300 browser_sync::SyncPrefs::RegisterProfilePrefs(registry); |
| 298 ChromeContentBrowserClient::RegisterProfilePrefs(registry); | 301 ChromeContentBrowserClient::RegisterProfilePrefs(registry); |
| 299 ChromeVersionService::RegisterProfilePrefs(registry); | 302 ChromeVersionService::RegisterProfilePrefs(registry); |
| 300 chrome_browser_net::HttpServerPropertiesManager::RegisterProfilePrefs( | 303 chrome_browser_net::HttpServerPropertiesManager::RegisterProfilePrefs( |
| 301 registry); | 304 registry); |
| 302 chrome_browser_net::Predictor::RegisterProfilePrefs(registry); | 305 chrome_browser_net::Predictor::RegisterProfilePrefs(registry); |
| 303 DownloadPrefs::RegisterProfilePrefs(registry); | 306 DownloadPrefs::RegisterProfilePrefs(registry); |
| 304 extensions::ExtensionPrefs::RegisterProfilePrefs(registry); | 307 extensions::ExtensionPrefs::RegisterProfilePrefs(registry); |
| (...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 509 } | 512 } |
| 510 local_state->ClearPref(prefs::kLastPromptedGoogleURL); | 513 local_state->ClearPref(prefs::kLastPromptedGoogleURL); |
| 511 | 514 |
| 512 current_version |= GOOGLE_URL_TRACKER_PREFS; | 515 current_version |= GOOGLE_URL_TRACKER_PREFS; |
| 513 local_state->SetInteger(prefs::kMultipleProfilePrefMigration, | 516 local_state->SetInteger(prefs::kMultipleProfilePrefMigration, |
| 514 current_version); | 517 current_version); |
| 515 } | 518 } |
| 516 } | 519 } |
| 517 | 520 |
| 518 } // namespace chrome | 521 } // namespace chrome |
| OLD | NEW |