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

Unified Diff: components/policy/core/common/cloud/cloud_policy_client.cc

Issue 2422083002: Remove usage of FOR_EACH_OBSERVER macro in components/policy (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/policy/core/common/cloud/cloud_policy_client.cc
diff --git a/components/policy/core/common/cloud/cloud_policy_client.cc b/components/policy/core/common/cloud/cloud_policy_client.cc
index ea5ba54ec22c1238c16711a18c1833c48aa1e66c..5440bddcc4f9b2416cfdec6027f475c25e987aaa 100644
--- a/components/policy/core/common/cloud/cloud_policy_client.cc
+++ b/components/policy/core/common/cloud/cloud_policy_client.cc
@@ -769,19 +769,23 @@ void CloudPolicyClient::OnGcmIdUpdated(
}
void CloudPolicyClient::NotifyPolicyFetched() {
- FOR_EACH_OBSERVER(Observer, observers_, OnPolicyFetched(this));
+ for (auto& observer : observers_)
+ observer.OnPolicyFetched(this);
}
void CloudPolicyClient::NotifyRegistrationStateChanged() {
- FOR_EACH_OBSERVER(Observer, observers_, OnRegistrationStateChanged(this));
+ for (auto& observer : observers_)
+ observer.OnRegistrationStateChanged(this);
}
void CloudPolicyClient::NotifyRobotAuthCodesFetched() {
- FOR_EACH_OBSERVER(Observer, observers_, OnRobotAuthCodesFetched(this));
+ for (auto& observer : observers_)
+ observer.OnRobotAuthCodesFetched(this);
}
void CloudPolicyClient::NotifyClientError() {
- FOR_EACH_OBSERVER(Observer, observers_, OnClientError(this));
+ for (auto& observer : observers_)
+ observer.OnClientError(this);
}
} // namespace policy

Powered by Google App Engine
This is Rietveld 408576698