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

Unified Diff: blimp/client/core/contents/blimp_contents_impl.cc

Issue 2425493002: Remove usage of FOR_EACH_OBSERVER macro in blimp (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 | « no previous file | blimp/client/core/session/connection_status.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: blimp/client/core/contents/blimp_contents_impl.cc
diff --git a/blimp/client/core/contents/blimp_contents_impl.cc b/blimp/client/core/contents/blimp_contents_impl.cc
index 42e9a1a3ad7c9b2fb01b6d3e08f86a817a96ea03..5cd4bb18f3d4b3a25c3a81fcd3f254ba768c95b4 100644
--- a/blimp/client/core/contents/blimp_contents_impl.cc
+++ b/blimp/client/core/contents/blimp_contents_impl.cc
@@ -45,7 +45,8 @@ BlimpContentsImpl::BlimpContentsImpl(
}
BlimpContentsImpl::~BlimpContentsImpl() {
- FOR_EACH_OBSERVER(BlimpContentsObserver, observers_, BlimpContentsDying());
+ for (auto& observer : observers_)
+ observer.BlimpContentsDying();
ime_feature_->set_delegate(nullptr);
}
@@ -103,18 +104,18 @@ bool BlimpContentsImpl::HasObserver(BlimpContentsObserver* observer) {
}
void BlimpContentsImpl::OnNavigationStateChanged() {
- FOR_EACH_OBSERVER(BlimpContentsObserver, observers_,
- OnNavigationStateChanged());
+ for (auto& observer : observers_)
+ observer.OnNavigationStateChanged();
}
void BlimpContentsImpl::OnLoadingStateChanged(bool loading) {
- FOR_EACH_OBSERVER(BlimpContentsObserver, observers_,
- OnLoadingStateChanged(loading));
+ for (auto& observer : observers_)
+ observer.OnLoadingStateChanged(loading);
}
void BlimpContentsImpl::OnPageLoadingStateChanged(bool loading) {
- FOR_EACH_OBSERVER(BlimpContentsObserver, observers_,
- OnPageLoadingStateChanged(loading));
+ for (auto& observer : observers_)
+ observer.OnPageLoadingStateChanged(loading);
}
void BlimpContentsImpl::SetSizeAndScale(const gfx::Size& size,
« no previous file with comments | « no previous file | blimp/client/core/session/connection_status.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698