| Index: chrome/browser/pref_service.h
|
| diff --git a/chrome/browser/pref_service.h b/chrome/browser/pref_service.h
|
| index 85dd42ca8f7858ef2e18d44814ea8e9bc49b56bb..f1819adf4e6973f1cfbaaae9089903dac1cae158 100644
|
| --- a/chrome/browser/pref_service.h
|
| +++ b/chrome/browser/pref_service.h
|
| @@ -27,6 +27,7 @@
|
|
|
| class NotificationObserver;
|
| class Preference;
|
| +class ScopedPrefUpdate;
|
|
|
| class PrefService : public NonThreadSafe,
|
| public ImportantFileWriter::DataSerializer {
|
| @@ -158,7 +159,8 @@ class PrefService : public NonThreadSafe,
|
| // This method returns NULL only if you're requesting an unregistered pref or
|
| // a non-dict/non-list pref.
|
| // WARNING: Changes to the dictionary or list will not automatically notify
|
| - // pref observers. TODO(tc): come up with a way to still fire observers.
|
| + // pref observers.
|
| + // Use a ScopedPrefUpdate to update observers on changes.
|
| DictionaryValue* GetMutableDictionary(const wchar_t* path);
|
| ListValue* GetMutableList(const wchar_t* path);
|
|
|
| @@ -216,6 +218,8 @@ class PrefService : public NonThreadSafe,
|
| PrefObserverMap;
|
| PrefObserverMap pref_observers_;
|
|
|
| + friend class ScopedPrefUpdate;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(PrefService);
|
| };
|
|
|
|
|