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

Side by Side Diff: content/browser/webrtc/webrtc_internals.cc

Issue 2422923002: Reduce usage of FOR_EACH_OBSERVER macro in content/browser (Closed)
Patch Set: skip cases in 2418143004 and 2418373002 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 unified diff | Download patch
« no previous file with comments | « content/browser/tracing/tracing_controller_impl.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/webrtc/webrtc_internals.h" 5 #include "content/browser/webrtc/webrtc_internals.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <memory> 9 #include <memory>
10 #include <utility> 10 #include <utility>
(...skipping 509 matching lines...) Expand 10 before | Expand all | Expand 10 after
520 "WebRTC has active PeerConnections", 520 "WebRTC has active PeerConnections",
521 BrowserThread::GetTaskRunnerForThread(BrowserThread::UI), 521 BrowserThread::GetTaskRunnerForThread(BrowserThread::UI),
522 BrowserThread::GetTaskRunnerForThread(BrowserThread::FILE))); 522 BrowserThread::GetTaskRunnerForThread(BrowserThread::FILE)));
523 } 523 }
524 } 524 }
525 525
526 void WebRTCInternals::ProcessPendingUpdates() { 526 void WebRTCInternals::ProcessPendingUpdates() {
527 DCHECK_CURRENTLY_ON(BrowserThread::UI); 527 DCHECK_CURRENTLY_ON(BrowserThread::UI);
528 while (!pending_updates_.empty()) { 528 while (!pending_updates_.empty()) {
529 const auto& update = pending_updates_.front(); 529 const auto& update = pending_updates_.front();
530 FOR_EACH_OBSERVER(WebRTCInternalsUIObserver, 530 for (auto& observer : observers_)
531 observers_, 531 observer.OnUpdate(update.command(), update.value());
532 OnUpdate(update.command(), update.value()));
533 pending_updates_.pop(); 532 pending_updates_.pop();
534 } 533 }
535 } 534 }
536 535
537 } // namespace content 536 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/tracing/tracing_controller_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698