Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1055)

Unified Diff: chrome/browser/prefs/profile_pref_store_manager.cc

Issue 266553002: Add TrackedPreferenceValidationDelegate (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: sync to r272759 Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/prefs/profile_pref_store_manager.cc
diff --git a/chrome/browser/prefs/profile_pref_store_manager.cc b/chrome/browser/prefs/profile_pref_store_manager.cc
index b47e3d99159f0bb299313f6e5e4a0427fcf55486..d5a64b05a4b8502064d0d1d536fce315db014b7f 100644
--- a/chrome/browser/prefs/profile_pref_store_manager.cc
+++ b/chrome/browser/prefs/profile_pref_store_manager.cc
@@ -182,6 +182,7 @@ void InitializeHashStoreObserver::OnInitializationCompleted(bool succeeded) {
if (succeeded && pre_update_version < PrefHashStoreImpl::VERSION_LATEST) {
PrefHashFilter(pref_hash_store_impl_.PassAs<PrefHashStore>(),
tracking_configuration_,
+ NULL,
reporting_ids_count_).Initialize(*pref_store_);
UMA_HISTOGRAM_ENUMERATION(
"Settings.TrackedPreferencesAlternateStoreVersionUpdatedFrom",
@@ -259,7 +260,8 @@ void ProfilePrefStoreManager::ResetPrefHashStore() {
}
PersistentPrefStore* ProfilePrefStoreManager::CreateProfilePrefStore(
- const scoped_refptr<base::SequencedTaskRunner>& io_task_runner) {
+ const scoped_refptr<base::SequencedTaskRunner>& io_task_runner,
+ TrackedPreferenceValidationDelegate* validation_delegate) {
scoped_ptr<PrefFilter> pref_filter;
if (!kPlatformSupportsPreferenceTracking) {
return new JsonPrefStore(GetPrefFilePathFromProfilePath(profile_path_),
@@ -289,10 +291,12 @@ PersistentPrefStore* ProfilePrefStoreManager::CreateProfilePrefStore(
scoped_ptr<PrefHashFilter> unprotected_pref_hash_filter(
new PrefHashFilter(GetPrefHashStoreImpl().PassAs<PrefHashStore>(),
unprotected_configuration,
+ validation_delegate,
reporting_ids_count_));
scoped_ptr<PrefHashFilter> protected_pref_hash_filter(
new PrefHashFilter(GetPrefHashStoreImpl().PassAs<PrefHashStore>(),
protected_configuration,
+ validation_delegate,
reporting_ids_count_));
PrefHashFilter* raw_unprotected_pref_hash_filter =
@@ -377,6 +381,7 @@ bool ProfilePrefStoreManager::InitializePrefsFromMasterPrefs(
new DictionaryPrefStore(&master_prefs));
PrefHashFilter(GetPrefHashStoreImpl().PassAs<PrefHashStore>(),
tracking_configuration_,
+ NULL,
reporting_ids_count_).Initialize(*pref_store);
}
@@ -392,6 +397,7 @@ ProfilePrefStoreManager::CreateDeprecatedCombinedProfilePrefStore(
pref_filter.reset(
new PrefHashFilter(GetPrefHashStoreImpl().PassAs<PrefHashStore>(),
tracking_configuration_,
+ NULL,
reporting_ids_count_));
}
return new JsonPrefStore(GetPrefFilePathFromProfilePath(profile_path_),

Powered by Google App Engine
This is Rietveld 408576698