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

Unified Diff: chrome/browser/extensions/external_pref_loader.cc

Issue 1326353002: Remove dependency of PrefSyncableService on Profile. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@pref_model_associator
Patch Set: Fixing ChromeOS and Linux compilation Created 5 years, 3 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/extensions/external_pref_loader.cc
diff --git a/chrome/browser/extensions/external_pref_loader.cc b/chrome/browser/extensions/external_pref_loader.cc
index d5509276e88abbc69f2c79aec33d98ddd3eedaba..9d9aed6d774580d0f71e35a24d94685612395c50 100644
--- a/chrome/browser/extensions/external_pref_loader.cc
+++ b/chrome/browser/extensions/external_pref_loader.cc
@@ -17,6 +17,7 @@
#include "base/strings/utf_string_conversions.h"
#include "chrome/browser/defaults.h"
#include "chrome/browser/prefs/pref_service_syncable.h"
+#include "chrome/browser/prefs/pref_service_syncable_util.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/sync/profile_sync_service_factory.h"
#include "chrome/common/chrome_paths.h"
@@ -121,7 +122,7 @@ void ExternalPrefLoader::StartLoading() {
(profile_ && profile_->IsSyncAllowed())) {
if (!PostLoadIfPrioritySyncReady()) {
DCHECK(profile_);
- PrefServiceSyncable* prefs = PrefServiceSyncable::FromProfile(profile_);
+ PrefServiceSyncable* prefs = PrefServiceSyncableFromProfile(profile_);
DCHECK(prefs);
syncable_pref_observer_.Add(prefs);
ProfileSyncService* service =
@@ -159,7 +160,7 @@ bool ExternalPrefLoader::PostLoadIfPrioritySyncReady() {
DCHECK(options_ & DELAY_LOAD_UNTIL_PRIORITY_SYNC);
DCHECK(profile_);
- PrefServiceSyncable* prefs = PrefServiceSyncable::FromProfile(profile_);
+ PrefServiceSyncable* prefs = PrefServiceSyncableFromProfile(profile_);
DCHECK(prefs);
if (prefs->IsPrioritySyncing()) {
PostLoadAndRemoveObservers();
@@ -170,7 +171,7 @@ bool ExternalPrefLoader::PostLoadIfPrioritySyncReady() {
}
void ExternalPrefLoader::PostLoadAndRemoveObservers() {
- PrefServiceSyncable* prefs = PrefServiceSyncable::FromProfile(profile_);
+ PrefServiceSyncable* prefs = PrefServiceSyncableFromProfile(profile_);
DCHECK(prefs);
syncable_pref_observer_.Remove(prefs);
« no previous file with comments | « chrome/browser/chromeos/preferences.cc ('k') | chrome/browser/extensions/external_provider_impl_chromeos_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698