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

Unified Diff: components/arc/arc_bridge_service.cc

Issue 2416633002: Remove FOR_EACH_OBSERVER from arc/ since it's being deprecated (Closed)
Patch Set: remove braces 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/arc/arc_bridge_bootstrap.cc ('k') | components/arc/instance_holder.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/arc/arc_bridge_service.cc
diff --git a/components/arc/arc_bridge_service.cc b/components/arc/arc_bridge_service.cc
index 20cbb7da43b5b1ad04048417c97640c3257c69ad..be3e44d1597fd85c2c113e7ec46d2a71556937ad 100644
--- a/components/arc/arc_bridge_service.cc
+++ b/components/arc/arc_bridge_service.cc
@@ -73,10 +73,13 @@ void ArcBridgeService::SetState(State state) {
DCHECK_NE(state_, state);
state_ = state;
VLOG(2) << "State: " << static_cast<uint32_t>(state_);
- if (state_ == State::READY)
- FOR_EACH_OBSERVER(Observer, observer_list(), OnBridgeReady());
- else if (state == State::STOPPED)
- FOR_EACH_OBSERVER(Observer, observer_list(), OnBridgeStopped(stop_reason_));
+ if (state_ == State::READY) {
+ for (auto& observer : observer_list())
+ observer.OnBridgeReady();
+ } else if (state == State::STOPPED) {
+ for (auto& observer : observer_list())
Yusuke Sato 2016/10/12 18:30:35 Added <LF> since line 80-81 does not fit in one li
+ observer.OnBridgeStopped(stop_reason_);
+ }
}
void ArcBridgeService::SetStopReason(StopReason stop_reason) {
« no previous file with comments | « components/arc/arc_bridge_bootstrap.cc ('k') | components/arc/instance_holder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698