| 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 "base/prefs/pref_service.h" | 7 #include "base/prefs/pref_service.h" |
| 8 #include "components/autofill/core/browser/autofill_manager.h" | 8 #include "components/autofill/core/browser/autofill_manager.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/data_reduction_proxy/core/browser/data_reduction_proxy_pref
s.h" | 10 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_pref
s.h" |
| 11 #include "components/data_reduction_proxy/core/common/data_reduction_proxy_pref_
names.h" | |
| 12 #include "components/dom_distiller/core/distilled_page_prefs.h" | 11 #include "components/dom_distiller/core/distilled_page_prefs.h" |
| 13 #include "components/enhanced_bookmarks/bookmark_server_cluster_service.h" | 12 #include "components/enhanced_bookmarks/bookmark_server_cluster_service.h" |
| 14 #include "components/gcm_driver/gcm_channel_status_syncer.h" | 13 #include "components/gcm_driver/gcm_channel_status_syncer.h" |
| 15 #include "components/network_time/network_time_tracker.h" | 14 #include "components/network_time/network_time_tracker.h" |
| 16 #include "components/omnibox/browser/zero_suggest_provider.h" | 15 #include "components/omnibox/browser/zero_suggest_provider.h" |
| 17 #include "components/password_manager/core/browser/password_manager.h" | 16 #include "components/password_manager/core/browser/password_manager.h" |
| 18 #include "components/pref_registry/pref_registry_syncable.h" | 17 #include "components/pref_registry/pref_registry_syncable.h" |
| 19 #include "components/proxy_config/pref_proxy_config_tracker_impl.h" | 18 #include "components/proxy_config/pref_proxy_config_tracker_impl.h" |
| 20 #include "components/rappor/rappor_service.h" | 19 #include "components/rappor/rappor_service.h" |
| 21 #include "components/search_engines/template_url_prepopulate_data.h" | 20 #include "components/search_engines/template_url_prepopulate_data.h" |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 60 | 59 |
| 61 // Preferences related to the browser state manager. | 60 // Preferences related to the browser state manager. |
| 62 registry->RegisterStringPref(ios::prefs::kBrowserStateLastUsed, | 61 registry->RegisterStringPref(ios::prefs::kBrowserStateLastUsed, |
| 63 std::string()); | 62 std::string()); |
| 64 registry->RegisterIntegerPref(ios::prefs::kBrowserStatesNumCreated, 1); | 63 registry->RegisterIntegerPref(ios::prefs::kBrowserStatesNumCreated, 1); |
| 65 registry->RegisterListPref(ios::prefs::kBrowserStatesLastActive); | 64 registry->RegisterListPref(ios::prefs::kBrowserStatesLastActive); |
| 66 | 65 |
| 67 [OmniboxGeolocationLocalState registerLocalState:registry]; | 66 [OmniboxGeolocationLocalState registerLocalState:registry]; |
| 68 [MemoryDebuggerManager registerLocalState:registry]; | 67 [MemoryDebuggerManager registerLocalState:registry]; |
| 69 | 68 |
| 70 // TODO(crbug.com/557814): data_reduction_proxy::prefs::kDataReductionProxy | |
| 71 // should be registered by data_reduction_proxy::RegisterPrefs() instead of | |
| 72 // here. | |
| 73 registry->RegisterStringPref(data_reduction_proxy::prefs::kDataReductionProxy, | |
| 74 std::string()); | |
| 75 data_reduction_proxy::RegisterPrefs(registry); | 69 data_reduction_proxy::RegisterPrefs(registry); |
| 76 | 70 |
| 77 // TODO(shreyasv): Remove this in M49 as almost all users would have the | 71 // TODO(shreyasv): Remove this in M49 as almost all users would have the |
| 78 // "do not backup" bit set by then. crbug.com/489865. | 72 // "do not backup" bit set by then. crbug.com/489865. |
| 79 registry->RegisterBooleanPref(prefs::kOTRStashStatePathSystemBackupExcluded, | 73 registry->RegisterBooleanPref(prefs::kOTRStashStatePathSystemBackupExcluded, |
| 80 false); | 74 false); |
| 81 registry->RegisterBooleanPref(prefs::kBrowsingDataMigrationHasBeenPossible, | 75 registry->RegisterBooleanPref(prefs::kBrowsingDataMigrationHasBeenPossible, |
| 82 false); | 76 false); |
| 83 | 77 |
| 84 ApplicationContextImpl::RegisterPrefs(registry); | 78 ApplicationContextImpl::RegisterPrefs(registry); |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 140 | 134 |
| 141 // This method should be periodically pruned of year+ old migrations. | 135 // This method should be periodically pruned of year+ old migrations. |
| 142 void MigrateObsoleteBrowserStatePrefs(PrefService* prefs) { | 136 void MigrateObsoleteBrowserStatePrefs(PrefService* prefs) { |
| 143 // Added 07/2014. | 137 // Added 07/2014. |
| 144 translate::TranslatePrefs::MigrateUserPrefs(prefs, | 138 translate::TranslatePrefs::MigrateUserPrefs(prefs, |
| 145 ios::prefs::kAcceptLanguages); | 139 ios::prefs::kAcceptLanguages); |
| 146 | 140 |
| 147 // Added 08/2015. | 141 // Added 08/2015. |
| 148 prefs->ClearPref(::prefs::kSigninSharedAuthenticationUserId); | 142 prefs->ClearPref(::prefs::kSigninSharedAuthenticationUserId); |
| 149 } | 143 } |
| OLD | NEW |