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

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

Issue 511393003: No longer register app window placement preference keys on the fly. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: update to ToT Created 6 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
« no previous file with comments | « chrome/browser/prefs/browser_ui_prefs_migrator_unittest.cc ('k') | chrome/browser/ui/browser.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/prefs/chrome_pref_service_factory.cc
diff --git a/chrome/browser/prefs/chrome_pref_service_factory.cc b/chrome/browser/prefs/chrome_pref_service_factory.cc
index 88acebfc5e803961e9f06131485d656a27b8afc3..57a184c472fa3961677855933d1d417a6421b2e8 100644
--- a/chrome/browser/prefs/chrome_pref_service_factory.cc
+++ b/chrome/browser/prefs/chrome_pref_service_factory.cc
@@ -25,6 +25,7 @@
#include "base/threading/sequenced_worker_pool.h"
#include "base/time/time.h"
#include "chrome/browser/browser_process.h"
+#include "chrome/browser/prefs/browser_ui_prefs_migrator.h"
#include "chrome/browser/prefs/command_line_pref_store.h"
#include "chrome/browser/prefs/pref_hash_filter.h"
#include "chrome/browser/prefs/pref_model_associator.h"
@@ -469,14 +470,18 @@ scoped_ptr<PrefServiceSyncable> CreateProfilePrefs(
syncer::PREFERENCES);
PrefServiceSyncableFactory factory;
+ scoped_refptr<PersistentPrefStore> user_pref_store(
+ CreateProfilePrefStoreManager(profile_path)
+ ->CreateProfilePrefStore(pref_io_task_runner,
+ start_sync_flare_for_prefs,
+ validation_delegate));
+ // BrowserUIPrefsMigrator unregisters and deletes itself after it is done.
+ user_pref_store->AddObserver(
+ new BrowserUIPrefsMigrator(user_pref_store.get()));
PrepareFactory(&factory,
policy_service,
supervised_user_settings,
- scoped_refptr<PersistentPrefStore>(
- CreateProfilePrefStoreManager(profile_path)
- ->CreateProfilePrefStore(pref_io_task_runner,
- start_sync_flare_for_prefs,
- validation_delegate)),
+ user_pref_store,
extension_prefs,
async);
scoped_ptr<PrefServiceSyncable> pref_service =
« no previous file with comments | « chrome/browser/prefs/browser_ui_prefs_migrator_unittest.cc ('k') | chrome/browser/ui/browser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698