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

Unified Diff: remoting/protocol/webrtc_audio_source_adapter.cc

Issue 2425483002: Remove usage of FOR_EACH_OBSERVER macro in remoting (Closed)
Patch Set: 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 | « remoting/host/daemon_process.cc ('k') | remoting/signaling/delegating_signal_strategy.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/webrtc_audio_source_adapter.cc
diff --git a/remoting/protocol/webrtc_audio_source_adapter.cc b/remoting/protocol/webrtc_audio_source_adapter.cc
index d9d9ca3817c602da9b5cd03b65d90bc92b1ce434..d89e38bce238c9e0a6c9b4b6ff5626cf1862ce11 100644
--- a/remoting/protocol/webrtc_audio_source_adapter.cc
+++ b/remoting/protocol/webrtc_audio_source_adapter.cc
@@ -125,15 +125,17 @@ void WebrtcAudioSourceAdapter::Core::OnAudioPacket(
// Here |partial_frame_| always contains a full frame.
DCHECK_EQ(partial_frame_.size(), bytes_per_frame);
- FOR_EACH_OBSERVER(webrtc::AudioTrackSinkInterface, audio_sinks_,
- OnData(&partial_frame_.front(), kBytesPerSample * 8,
- sampling_rate_, kChannels, samples_per_frame));
+ for (auto& observer : audio_sinks_) {
+ observer.OnData(&partial_frame_.front(), kBytesPerSample * 8,
+ sampling_rate_, kChannels, samples_per_frame);
+ }
}
while (position + bytes_per_frame <= data.size()) {
- FOR_EACH_OBSERVER(webrtc::AudioTrackSinkInterface, audio_sinks_,
- OnData(data.data() + position, kBytesPerSample * 8,
- sampling_rate_, kChannels, samples_per_frame));
+ for (auto& observer : audio_sinks_) {
+ observer.OnData(data.data() + position, kBytesPerSample * 8,
+ sampling_rate_, kChannels, samples_per_frame);
+ }
position += bytes_per_frame;
}
« no previous file with comments | « remoting/host/daemon_process.cc ('k') | remoting/signaling/delegating_signal_strategy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698