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

Unified Diff: content/renderer/media/webrtc/media_stream_remote_audio_track.cc

Issue 1780653002: Revert of MediaStream audio object graph untangling and clean-ups. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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: content/renderer/media/webrtc/media_stream_remote_audio_track.cc
diff --git a/content/renderer/media/webrtc/media_stream_remote_audio_track.cc b/content/renderer/media/webrtc/media_stream_remote_audio_track.cc
index d03c80676ea49e8453b7d402c61dab2fdf98b927..e1b52883e82281dc496d55d1462741ca1bf6a048 100644
--- a/content/renderer/media/webrtc/media_stream_remote_audio_track.cc
+++ b/content/renderer/media/webrtc/media_stream_remote_audio_track.cc
@@ -120,8 +120,7 @@
MediaStreamRemoteAudioTrack::~MediaStreamRemoteAudioTrack() {
DCHECK(main_render_thread_checker_.CalledOnValidThread());
- // Ensure the track is stopped.
- MediaStreamAudioTrack::Stop();
+ source()->RemoveAll(this);
}
void MediaStreamRemoteAudioTrack::SetEnabled(bool enabled) {
@@ -140,12 +139,8 @@
source()->SetSinksEnabled(this, enabled);
}
-void MediaStreamRemoteAudioTrack::OnStop() {
- DCHECK(main_render_thread_checker_.CalledOnValidThread());
- DVLOG(1) << "MediaStreamRemoteAudioTrack::OnStop()";
-
- source()->RemoveAll(this);
-
+void MediaStreamRemoteAudioTrack::Stop() {
+ DCHECK(main_render_thread_checker_.CalledOnValidThread());
// Stop means that a track should be stopped permanently. But
// since there is no proper way of doing that on a remote track, we can
// at least disable the track. Blink will not call down to the content layer

Powered by Google App Engine
This is Rietveld 408576698