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

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

Issue 11741003: Remove PrefServiceSimple, replacing it with PrefService and PrefRegistrySimple. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix double registration in Chrome Frame test. 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
« no previous file with comments | « chrome/browser/prefs/pref_service_syncable.cc ('k') | chrome/browser/prefs/pref_service_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/prefs/pref_service_syncable_builder.cc
diff --git a/chrome/browser/prefs/pref_service_syncable_builder.cc b/chrome/browser/prefs/pref_service_syncable_builder.cc
index 4c1327751800205c3089cea10ab37079e2f44251..8a157dd310bda24b78828dfcd55b21c060a527c2 100644
--- a/chrome/browser/prefs/pref_service_syncable_builder.cc
+++ b/chrome/browser/prefs/pref_service_syncable_builder.cc
@@ -9,6 +9,7 @@
#include "chrome/browser/policy/policy_service.h"
#include "chrome/browser/prefs/command_line_pref_store.h"
#include "chrome/browser/prefs/pref_notifier_impl.h"
+#include "chrome/browser/prefs/pref_registry_simple.h"
#include "chrome/browser/prefs/pref_service_syncable.h"
#include "chrome/browser/prefs/pref_value_store.h"
@@ -41,7 +42,8 @@ PrefServiceSyncableBuilder::WithCommandLine(CommandLine* command_line) {
}
PrefServiceSyncable* PrefServiceSyncableBuilder::CreateSyncable() {
- DefaultPrefStore* default_pref_store = new DefaultPrefStore();
+ // TODO(joi): Switch to accepting a PrefRegistrySyncable parameter.
+ scoped_refptr<PrefRegistry> pref_registry = new PrefRegistrySimple();
PrefNotifierImpl* pref_notifier = new PrefNotifierImpl();
PrefServiceSyncable* pref_service = new PrefServiceSyncable(
pref_notifier,
@@ -51,10 +53,10 @@ PrefServiceSyncable* PrefServiceSyncableBuilder::CreateSyncable() {
command_line_prefs_.get(),
user_prefs_.get(),
recommended_prefs_.get(),
- default_pref_store,
+ pref_registry->defaults(),
pref_notifier),
user_prefs_.get(),
- default_pref_store,
+ pref_registry.get(),
read_error_callback_,
async_);
ResetDefaultState();
« no previous file with comments | « chrome/browser/prefs/pref_service_syncable.cc ('k') | chrome/browser/prefs/pref_service_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698