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

Unified Diff: chrome/browser/sync/profile_sync_components_factory_impl.cc

Issue 12033093: sync: Implementation of Priority Preferences. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Attempting to parametrize the PSS pref test fixture to also test priority prefs. Created 7 years, 10 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/sync/profile_sync_components_factory_impl.cc
diff --git a/chrome/browser/sync/profile_sync_components_factory_impl.cc b/chrome/browser/sync/profile_sync_components_factory_impl.cc
index 0fe3a29e763404cb1fe9a9fa497656c5eb43c2cd..ea7ece8a8b0545f9d4714906447cb5e505fdb91c 100644
--- a/chrome/browser/sync/profile_sync_components_factory_impl.cc
+++ b/chrome/browser/sync/profile_sync_components_factory_impl.cc
@@ -191,6 +191,9 @@ void ProfileSyncComponentsFactoryImpl::RegisterDesktopDataTypes(
if (!command_line_->HasSwitch(switches::kDisableSyncPreferences)) {
pss->RegisterDataTypeController(
new UIDataTypeController(syncer::PREFERENCES, this, profile_, pss));
+ pss->RegisterDataTypeController(
+ new UIDataTypeController(syncer::PRIORITY_PREFERENCES,
+ this, profile_, pss));
}
#if defined(ENABLE_THEMES)
@@ -301,7 +304,10 @@ base::WeakPtr<syncer::SyncableService> ProfileSyncComponentsFactoryImpl::
switch (type) {
case syncer::PREFERENCES:
return PrefServiceSyncable::FromProfile(
- profile_)->GetSyncableService()->AsWeakPtr();
+ profile_)->GetSyncableService(syncer::PREFERENCES)->AsWeakPtr();
+ case syncer::PRIORITY_PREFERENCES:
+ return PrefServiceSyncable::FromProfile(profile_)->GetSyncableService(
+ syncer::PRIORITY_PREFERENCES)->AsWeakPtr();
case syncer::AUTOFILL:
case syncer::AUTOFILL_PROFILE: {
if (!web_data_service_.get())

Powered by Google App Engine
This is Rietveld 408576698