| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "ios/chrome/browser/prefs/browser_prefs.h" | 5 #include "ios/chrome/browser/prefs/browser_prefs.h" |
| 6 | 6 |
| 7 #include "components/autofill/core/browser/autofill_manager.h" | 7 #include "components/autofill/core/browser/autofill_manager.h" |
| 8 #include "components/browsing_data/core/pref_names.h" | 8 #include "components/browsing_data/core/pref_names.h" |
| 9 #include "components/content_settings/core/browser/host_content_settings_map.h" | 9 #include "components/content_settings/core/browser/host_content_settings_map.h" |
| 10 #include "components/dom_distiller/core/distilled_page_prefs.h" | 10 #include "components/dom_distiller/core/distilled_page_prefs.h" |
| 11 #include "components/flags_ui/pref_service_flags_storage.h" | 11 #include "components/flags_ui/pref_service_flags_storage.h" |
| 12 #include "components/gcm_driver/gcm_channel_status_syncer.h" | 12 #include "components/gcm_driver/gcm_channel_status_syncer.h" |
| 13 #include "components/metrics/metrics_pref_names.h" | 13 #include "components/metrics/metrics_pref_names.h" |
| 14 #include "components/network_time/network_time_tracker.h" | 14 #include "components/network_time/network_time_tracker.h" |
| 15 #include "components/ntp_snippets/bookmarks/bookmark_suggestions_provider.h" | 15 #include "components/ntp_snippets/bookmarks/bookmark_suggestions_provider.h" |
| 16 #include "components/ntp_snippets/content_suggestions_service.h" | 16 #include "components/ntp_snippets/content_suggestions_service.h" |
| 17 #include "components/ntp_snippets/remote/remote_suggestions_provider.h" | 17 #include "components/ntp_snippets/remote/remote_suggestions_provider.h" |
| 18 #include "components/ntp_tiles/most_visited_sites.h" | 18 #include "components/ntp_tiles/most_visited_sites.h" |
| 19 #include "components/ntp_tiles/popular_sites.h" | 19 #include "components/ntp_tiles/popular_sites.h" |
| 20 #include "components/omnibox/browser/zero_suggest_provider.h" | 20 #include "components/omnibox/browser/zero_suggest_provider.h" |
| 21 #include "components/password_manager/core/browser/password_manager.h" | 21 #include "components/password_manager/core/browser/password_manager.h" |
| 22 #include "components/pref_registry/pref_registry_syncable.h" | 22 #include "components/pref_registry/pref_registry_syncable.h" |
| 23 #include "components/prefs/pref_service.h" | 23 #include "components/prefs/pref_service.h" |
| 24 #include "components/proxy_config/pref_proxy_config_tracker_impl.h" | 24 #include "components/proxy_config/pref_proxy_config_tracker_impl.h" |
| 25 #include "components/rappor/rappor_service.h" | 25 #include "components/rappor/rappor_service_impl.h" |
| 26 #include "components/search_engines/template_url_prepopulate_data.h" | 26 #include "components/search_engines/template_url_prepopulate_data.h" |
| 27 #include "components/signin/core/common/signin_pref_names.h" | 27 #include "components/signin/core/common/signin_pref_names.h" |
| 28 #include "components/ssl_config/ssl_config_service_manager.h" | 28 #include "components/ssl_config/ssl_config_service_manager.h" |
| 29 #include "components/strings/grit/components_locale_settings.h" | 29 #include "components/strings/grit/components_locale_settings.h" |
| 30 #include "components/sync/base/sync_prefs.h" | 30 #include "components/sync/base/sync_prefs.h" |
| 31 #include "components/translate/core/browser/translate_prefs.h" | 31 #include "components/translate/core/browser/translate_prefs.h" |
| 32 #include "components/translate/core/common/translate_pref_names.h" | 32 #include "components/translate/core/common/translate_pref_names.h" |
| 33 #include "components/update_client/update_client.h" | 33 #include "components/update_client/update_client.h" |
| 34 #include "components/variations/service/variations_service.h" | 34 #include "components/variations/service/variations_service.h" |
| 35 #include "components/web_resource/web_resource_pref_names.h" | 35 #include "components/web_resource/web_resource_pref_names.h" |
| (...skipping 12 matching lines...) Expand all Loading... |
| 48 | 48 |
| 49 void RegisterLocalStatePrefs(PrefRegistrySimple* registry) { | 49 void RegisterLocalStatePrefs(PrefRegistrySimple* registry) { |
| 50 BrowserStateInfoCache::RegisterPrefs(registry); | 50 BrowserStateInfoCache::RegisterPrefs(registry); |
| 51 flags_ui::PrefServiceFlagsStorage::RegisterPrefs(registry); | 51 flags_ui::PrefServiceFlagsStorage::RegisterPrefs(registry); |
| 52 gcm::GCMChannelStatusSyncer::RegisterPrefs(registry); | 52 gcm::GCMChannelStatusSyncer::RegisterPrefs(registry); |
| 53 ios::SigninManagerFactory::RegisterPrefs(registry); | 53 ios::SigninManagerFactory::RegisterPrefs(registry); |
| 54 IOSChromeMetricsServiceClient::RegisterPrefs(registry); | 54 IOSChromeMetricsServiceClient::RegisterPrefs(registry); |
| 55 network_time::NetworkTimeTracker::RegisterPrefs(registry); | 55 network_time::NetworkTimeTracker::RegisterPrefs(registry); |
| 56 ios::NotificationPromo::RegisterPrefs(registry); | 56 ios::NotificationPromo::RegisterPrefs(registry); |
| 57 PrefProxyConfigTrackerImpl::RegisterPrefs(registry); | 57 PrefProxyConfigTrackerImpl::RegisterPrefs(registry); |
| 58 rappor::RapporService::RegisterPrefs(registry); | 58 rappor::RapporServiceImpl::RegisterPrefs(registry); |
| 59 ssl_config::SSLConfigServiceManager::RegisterPrefs(registry); | 59 ssl_config::SSLConfigServiceManager::RegisterPrefs(registry); |
| 60 update_client::RegisterPrefs(registry); | 60 update_client::RegisterPrefs(registry); |
| 61 variations::VariationsService::RegisterPrefs(registry); | 61 variations::VariationsService::RegisterPrefs(registry); |
| 62 | 62 |
| 63 // Preferences related to the browser state manager. | 63 // Preferences related to the browser state manager. |
| 64 registry->RegisterStringPref(prefs::kBrowserStateLastUsed, std::string()); | 64 registry->RegisterStringPref(prefs::kBrowserStateLastUsed, std::string()); |
| 65 registry->RegisterIntegerPref(prefs::kBrowserStatesNumCreated, 1); | 65 registry->RegisterIntegerPref(prefs::kBrowserStatesNumCreated, 1); |
| 66 registry->RegisterListPref(prefs::kBrowserStatesLastActive); | 66 registry->RegisterListPref(prefs::kBrowserStatesLastActive); |
| 67 | 67 |
| 68 [OmniboxGeolocationLocalState registerLocalState:registry]; | 68 [OmniboxGeolocationLocalState registerLocalState:registry]; |
| (...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 145 } | 145 } |
| 146 | 146 |
| 147 // This method should be periodically pruned of year+ old migrations. | 147 // This method should be periodically pruned of year+ old migrations. |
| 148 void MigrateObsoleteBrowserStatePrefs(PrefService* prefs) { | 148 void MigrateObsoleteBrowserStatePrefs(PrefService* prefs) { |
| 149 // Added 07/2014. | 149 // Added 07/2014. |
| 150 translate::TranslatePrefs::MigrateUserPrefs(prefs, prefs::kAcceptLanguages); | 150 translate::TranslatePrefs::MigrateUserPrefs(prefs, prefs::kAcceptLanguages); |
| 151 | 151 |
| 152 // Added 08/2015. | 152 // Added 08/2015. |
| 153 prefs->ClearPref(::prefs::kSigninSharedAuthenticationUserId); | 153 prefs->ClearPref(::prefs::kSigninSharedAuthenticationUserId); |
| 154 } | 154 } |
| OLD | NEW |