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

Unified Diff: components/prefs/overlay_user_pref_store.cc

Issue 2444753002: Reduce usage of FOR_EACH_OBSERVER macro in components/ (Closed)
Patch Set: Created 4 years, 2 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 | « components/prefs/json_pref_store.cc ('k') | components/prefs/pref_notifier_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/prefs/overlay_user_pref_store.cc
diff --git a/components/prefs/overlay_user_pref_store.cc b/components/prefs/overlay_user_pref_store.cc
index 125dece15f893ca9ff0575946a8d137e35e45a3a..2b2208ed8214408290c312125e5309689dfecaff 100644
--- a/components/prefs/overlay_user_pref_store.cc
+++ b/components/prefs/overlay_user_pref_store.cc
@@ -130,7 +130,8 @@ void OverlayUserPrefStore::SchedulePendingLossyWrites() {
void OverlayUserPrefStore::ReportValueChanged(const std::string& key,
uint32_t flags) {
- FOR_EACH_OBSERVER(PrefStore::Observer, observers_, OnPrefValueChanged(key));
+ for (PrefStore::Observer& observer : observers_)
+ observer.OnPrefValueChanged(key);
}
void OverlayUserPrefStore::OnPrefValueChanged(const std::string& key) {
@@ -139,8 +140,8 @@ void OverlayUserPrefStore::OnPrefValueChanged(const std::string& key) {
}
void OverlayUserPrefStore::OnInitializationCompleted(bool succeeded) {
- FOR_EACH_OBSERVER(PrefStore::Observer, observers_,
- OnInitializationCompleted(succeeded));
+ for (PrefStore::Observer& observer : observers_)
+ observer.OnInitializationCompleted(succeeded);
}
void OverlayUserPrefStore::RegisterOverlayPref(const std::string& key) {
« no previous file with comments | « components/prefs/json_pref_store.cc ('k') | components/prefs/pref_notifier_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698