| Index: chrome/browser/prefs/pref_value_store.cc
|
| diff --git a/chrome/browser/prefs/pref_value_store.cc b/chrome/browser/prefs/pref_value_store.cc
|
| index 84b6919ec7067db82354d49ea8596d67b7c1a504..82ab2840441bb4565a5b8d30045e5b4aa72a12d5 100644
|
| --- a/chrome/browser/prefs/pref_value_store.cc
|
| +++ b/chrome/browser/prefs/pref_value_store.cc
|
| @@ -5,7 +5,6 @@
|
| #include "chrome/browser/prefs/pref_value_store.h"
|
|
|
| #include "chrome/browser/browser_thread.h"
|
| -#include "chrome/browser/extensions/extension_pref_store.h"
|
| #include "chrome/browser/policy/configuration_policy_pref_store.h"
|
| #include "chrome/browser/prefs/command_line_pref_store.h"
|
| #include "chrome/browser/prefs/in_memory_pref_store.h"
|
| @@ -41,7 +40,7 @@ PrefValueStore* PrefValueStore::CreatePrefValueStore(
|
| using policy::ConfigurationPolicyPrefStore;
|
| ConfigurationPolicyPrefStore* managed = NULL;
|
| ConfigurationPolicyPrefStore* device_management = NULL;
|
| - ExtensionPrefStore* extension = NULL;
|
| + InMemoryPrefStore* extension = NULL;
|
| CommandLinePrefStore* command_line = NULL;
|
| ConfigurationPolicyPrefStore* recommended = NULL;
|
|
|
| @@ -56,10 +55,14 @@ PrefValueStore* PrefValueStore::CreatePrefValueStore(
|
| device_management =
|
| ConfigurationPolicyPrefStore::CreateDeviceManagementPolicyPrefStore(
|
| profile);
|
| - extension = new ExtensionPrefStore(profile, PrefNotifier::EXTENSION_STORE);
|
| + extension = new InMemoryPrefStore();
|
| command_line = new CommandLinePrefStore(CommandLine::ForCurrentProcess());
|
| recommended =
|
| ConfigurationPolicyPrefStore::CreateRecommendedPolicyPrefStore();
|
| + } else {
|
| + // TODO(battre) This is a temporary hack to make the unit tests pass.
|
| + // need to think more whether this is correct.
|
| + extension = new InMemoryPrefStore();
|
| }
|
| return new PrefValueStore(managed, device_management, extension,
|
| command_line, user, recommended, default_store,
|
| @@ -154,7 +157,8 @@ bool PrefValueStore::PrefHasChanged(const char* path,
|
| return true;
|
|
|
| PrefNotifier::PrefStoreType controller = ControllingPrefStoreForPref(path);
|
| - DCHECK(controller != PrefNotifier::INVALID_STORE);
|
| + DCHECK(controller != PrefNotifier::INVALID_STORE)
|
| + << "Invalid controller for path " << path;
|
| if (controller == PrefNotifier::INVALID_STORE)
|
| return true;
|
|
|
| @@ -463,6 +467,10 @@ bool PrefValueStore::HasPolicyConflictingUserProxySettings() {
|
| return false;
|
| }
|
|
|
| +PrefStore* PrefValueStore::GetExtensionPrefStore() {
|
| + return pref_stores_[PrefNotifier::EXTENSION_STORE].get();
|
| +}
|
| +
|
| PrefValueStore::PrefValueStore(PrefStore* managed_platform_prefs,
|
| PrefStore* device_management_prefs,
|
| PrefStore* extension_prefs,
|
|
|