diff --git a/dom/media/MediaManager.cpp b/dom/media/MediaManager.cpp index d443e0054aa6..765bd2f2b752 100644 --- a/dom/media/MediaManager.cpp +++ b/dom/media/MediaManager.cpp @@ -800,17 +800,6 @@ public: } } - // let us intervene for direct listeners when someone does track.enabled = false - virtual void SetTrackEnabled(TrackID aTrackID, bool aEnabled) override - { - // We encapsulate the SourceMediaStream and TrackUnion into one entity, so - // we can handle the disabling at the SourceMediaStream - - // We need to find the input track ID for output ID aTrackID, so we let the TrackUnion - // forward the request to the source and translate the ID - GetInputStream()->AsProcessedStream()->ForwardTrackEnabled(aTrackID, aEnabled); - } - virtual DOMLocalMediaStream* AsDOMLocalMediaStream() override { return this; diff --git a/dom/media/MediaStreamGraph.h b/dom/media/MediaStreamGraph.h index 1fc405b1b871..0071111a1c57 100644 --- a/dom/media/MediaStreamGraph.h +++ b/dom/media/MediaStreamGraph.h @@ -1115,11 +1115,6 @@ public: virtual void ProcessInput(GraphTime aFrom, GraphTime aTo, uint32_t aFlags) = 0; void SetAutofinishImpl(bool aAutofinish) { mAutofinish = aAutofinish; } - /** - * Forward SetTrackEnabled() to the input MediaStream(s) and translate the ID - */ - virtual void ForwardTrackEnabled(TrackID aOutputID, bool aEnabled) {}; - // Only valid after MediaStreamGraphImpl::UpdateStreamOrder() has run. // A DelayNode is considered to break a cycle and so this will not return // true for echo loops, only for muted cycles. diff --git a/dom/media/TrackUnionStream.cpp b/dom/media/TrackUnionStream.cpp index 8310d22ac3ec..e4e844a4380c 100644 --- a/dom/media/TrackUnionStream.cpp +++ b/dom/media/TrackUnionStream.cpp @@ -149,18 +149,6 @@ TrackUnionStream::TrackUnionStream(DOMMediaStream* aWrapper) : } } - // Forward SetTrackEnabled(output_track_id, enabled) to the Source MediaStream, - // translating the output track ID into the correct ID in the source. - void TrackUnionStream::ForwardTrackEnabled(TrackID aOutputID, bool aEnabled) - { - for (int32_t i = mTrackMap.Length() - 1; i >= 0; --i) { - if (mTrackMap[i].mOutputTrackID == aOutputID) { - mTrackMap[i].mInputPort->GetSource()-> - SetTrackEnabled(mTrackMap[i].mInputTrackID, aEnabled); - } - } - } - uint32_t TrackUnionStream::AddTrack(MediaInputPort* aPort, StreamBuffer::Track* aTrack, GraphTime aFrom) { diff --git a/dom/media/TrackUnionStream.h b/dom/media/TrackUnionStream.h index e9dd97922515..009a3fac1e40 100644 --- a/dom/media/TrackUnionStream.h +++ b/dom/media/TrackUnionStream.h @@ -21,10 +21,6 @@ public: virtual void RemoveInput(MediaInputPort* aPort) override; virtual void ProcessInput(GraphTime aFrom, GraphTime aTo, uint32_t aFlags) override; - // Forward SetTrackEnabled(output_track_id, enabled) to the Source MediaStream, - // translating the output track ID into the correct ID in the source. - virtual void ForwardTrackEnabled(TrackID aOutputID, bool aEnabled) override; - protected: // Only non-ended tracks are allowed to persist in this map. struct TrackMapEntry {