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

Unified Diff: components/proxy_config/pref_proxy_config_tracker_impl.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
Index: components/proxy_config/pref_proxy_config_tracker_impl.cc
diff --git a/components/proxy_config/pref_proxy_config_tracker_impl.cc b/components/proxy_config/pref_proxy_config_tracker_impl.cc
index b4a2810a632cf1ddd86f7f3c82fb11d142d07b9b..cc824cc21c08e0d62c0c3df7ee9ef264035bc710 100644
--- a/components/proxy_config/pref_proxy_config_tracker_impl.cc
+++ b/components/proxy_config/pref_proxy_config_tracker_impl.cc
@@ -94,8 +94,8 @@ void ProxyConfigServiceImpl::UpdateProxyConfig(
net::ProxyConfig new_config;
ConfigAvailability availability = GetLatestProxyConfig(&new_config);
if (availability != CONFIG_PENDING) {
- FOR_EACH_OBSERVER(net::ProxyConfigService::Observer, observers_,
- OnProxyConfigChanged(new_config, availability));
+ for (net::ProxyConfigService::Observer& observer : observers_)
+ observer.OnProxyConfigChanged(new_config, availability);
}
}
@@ -110,8 +110,8 @@ void ProxyConfigServiceImpl::OnProxyConfigChanged(
if (!PrefProxyConfigTrackerImpl::PrefPrecedes(pref_config_state_)) {
net::ProxyConfig actual_config;
availability = GetLatestProxyConfig(&actual_config);
- FOR_EACH_OBSERVER(net::ProxyConfigService::Observer, observers_,
- OnProxyConfigChanged(actual_config, availability));
+ for (net::ProxyConfigService::Observer& observer : observers_)
+ observer.OnProxyConfigChanged(actual_config, availability);
}
}
« no previous file with comments | « components/prefs/value_map_pref_store.cc ('k') | components/proxy_config/pref_proxy_config_tracker_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698