Index: chrome/browser/prefs/pref_notifier_impl.h |
diff --git a/chrome/browser/prefs/pref_notifier_impl.h b/chrome/browser/prefs/pref_notifier_impl.h |
index 8323fcbec5bc3804384df50c59f8d0eb81c34d54..e776ddb9ed1fffdf1418eeadc6cf786d739cf2e2 100644 |
--- a/chrome/browser/prefs/pref_notifier_impl.h |
+++ b/chrome/browser/prefs/pref_notifier_impl.h |
@@ -13,14 +13,15 @@ |
#include "base/threading/non_thread_safe.h" |
#include "chrome/browser/prefs/pref_notifier.h" |
-class PrefService; |
class NotificationObserver; |
+class PrefModelAssociator; |
+class PrefService; |
// The PrefNotifier implementation used by the PrefService. |
class PrefNotifierImpl : public PrefNotifier, |
public base::NonThreadSafe { |
public: |
- explicit PrefNotifierImpl(PrefService* pref_service); |
+ PrefNotifierImpl(); |
virtual ~PrefNotifierImpl(); |
// If the pref at the given path changes, we call the observer's Observe |
@@ -32,6 +33,12 @@ class PrefNotifierImpl : public PrefNotifier, |
virtual void OnPreferenceChanged(const std::string& pref_name); |
virtual void OnInitializationCompleted(bool succeeded); |
+ // Sets the source PrefService. |
+ void SetSource(PrefService* pref_service); |
+ |
+ // Sets the associator. |
+ void SetPrefModelAssociator(PrefModelAssociator* associator); |
+ |
protected: |
// A map from pref names to a list of observers. Observers get fired in the |
// order they are added. These should only be accessed externally for unit |
@@ -52,6 +59,9 @@ class PrefNotifierImpl : public PrefNotifier, |
PrefObserverMap pref_observers_; |
+ // The sync associator that needs to be notified on every pref change. |
+ PrefModelAssociator* pref_model_associator_; |
+ |
DISALLOW_COPY_AND_ASSIGN(PrefNotifierImpl); |
}; |