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

Unified Diff: components/syncable_prefs/pref_model_associator.h

Issue 2318303002: Remove stl_util's STLDeleteContainerPairSecondPointers. (Closed)
Patch Set: fix Created 4 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
Index: components/syncable_prefs/pref_model_associator.h
diff --git a/components/syncable_prefs/pref_model_associator.h b/components/syncable_prefs/pref_model_associator.h
index 8938d14381eadf8e94f6251e908c1acb0e2f7d1a..34fa739c82d0618edb28074607ec4c478618b10e 100644
--- a/components/syncable_prefs/pref_model_associator.h
+++ b/components/syncable_prefs/pref_model_associator.h
@@ -190,13 +190,12 @@ class PrefModelAssociator
// Map prefs to lists of observers. Observers will receive notification when
// a pref changes, including the detail of whether or not the change came
// from sync.
battre 2016/09/22 16:44:24 I think that I would keep the typedef so that this
Avi (use Gerrit) 2016/09/22 19:17:17 Fixed.
- typedef base::ObserverList<SyncedPrefObserver> SyncedPrefObserverList;
- typedef base::hash_map<std::string, SyncedPrefObserverList*>
- SyncedPrefObserverMap;
+ using SyncedPrefObserverList = base::ObserverList<SyncedPrefObserver>;
void NotifySyncedPrefObservers(const std::string& path, bool from_sync) const;
- SyncedPrefObserverMap synced_pref_observers_;
+ base::hash_map<std::string, std::unique_ptr<SyncedPrefObserverList>>
+ synced_pref_observers_;
const PrefModelAssociatorClient* client_; // Weak.
std::vector<base::Closure> callback_list_;

Powered by Google App Engine
This is Rietveld 408576698