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

Unified Diff: chrome/browser/sync_file_system/local/local_file_sync_status.cc

Issue 2425553002: Remove FOR_EACH_OBSERVER macro usage in chrome/browser/sync_file_system (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: chrome/browser/sync_file_system/local/local_file_sync_status.cc
diff --git a/chrome/browser/sync_file_system/local/local_file_sync_status.cc b/chrome/browser/sync_file_system/local/local_file_sync_status.cc
index b26831ae1c306b20760ea4d669c880a36732a992..c375ff797225c40207a5f5b30aba85edfb7a8af6 100644
--- a/chrome/browser/sync_file_system/local/local_file_sync_status.cc
+++ b/chrome/browser/sync_file_system/local/local_file_sync_status.cc
@@ -94,7 +94,8 @@ void LocalFileSyncStatus::EndWriting(const FileSystemURL& url) {
writing_[origin_and_type].erase(normalized_path);
if (writing_[origin_and_type].empty())
writing_.erase(origin_and_type);
- FOR_EACH_OBSERVER(Observer, observer_list_, OnSyncEnabled(url));
+ for (auto& observer : observer_list_)
+ observer.OnSyncEnabled(url);
}
}
@@ -113,8 +114,10 @@ void LocalFileSyncStatus::EndSyncing(const FileSystemURL& url) {
syncing_[origin_and_type].erase(normalized_path);
if (syncing_[origin_and_type].empty())
syncing_.erase(origin_and_type);
- FOR_EACH_OBSERVER(Observer, observer_list_, OnSyncEnabled(url));
- FOR_EACH_OBSERVER(Observer, observer_list_, OnWriteEnabled(url));
+ for (auto& observer : observer_list_)
+ observer.OnSyncEnabled(url);
+ for (auto& observer : observer_list_)
+ observer.OnWriteEnabled(url);
}
bool LocalFileSyncStatus::IsWriting(const FileSystemURL& url) const {

Powered by Google App Engine
This is Rietveld 408576698