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

Unified Diff: third_party/WebKit/Source/modules/mediasource/SourceBuffer.cpp

Issue 2263823002: Deliver change notifications to SourceBuffer track lists. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Call VideoTrackList::trackSelected also the SourceBuffer track list Created 4 years, 4 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 | « third_party/WebKit/Source/modules/mediasource/SourceBuffer.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/modules/mediasource/SourceBuffer.cpp
diff --git a/third_party/WebKit/Source/modules/mediasource/SourceBuffer.cpp b/third_party/WebKit/Source/modules/mediasource/SourceBuffer.cpp
index 14fb000eb3b4d0f6b848663431438202fb9d19ff..58c74056c0aa95cff1584e1451963747d47ff7f4 100644
--- a/third_party/WebKit/Source/modules/mediasource/SourceBuffer.cpp
+++ b/third_party/WebKit/Source/modules/mediasource/SourceBuffer.cpp
@@ -669,7 +669,7 @@ bool SourceBuffer::initializationSegmentReceived(const WebVector<MediaTrackInfo>
if (!RuntimeEnabledFeatures::audioVideoTracksEnabled()) {
if (!m_firstInitializationSegmentReceived) {
- m_source->setSourceBufferActive(this);
+ m_source->setSourceBufferActive(this, true);
m_firstInitializationSegmentReceived = true;
}
return true;
@@ -764,7 +764,7 @@ bool SourceBuffer::initializationSegmentReceived(const WebVector<MediaTrackInfo>
}
// 4. Let active track flag equal false.
- m_activeTrack = false;
+ bool activeTrack = false;
// 5. If the first initialization segment received flag is false, then run the following steps:
if (!m_firstInitializationSegmentReceived) {
@@ -798,7 +798,7 @@ bool SourceBuffer::initializationSegmentReceived(const WebVector<MediaTrackInfo>
// 5.2.8.7.1 Set the enabled property on new audio track to true.
audioTrack->setEnabled(true);
// 5.2.8.7.2 Set active track flag to true.
- m_activeTrack = true;
+ activeTrack = true;
}
// 5.2.8.8 Add new audio track to the audioTracks attribute on this SourceBuffer object.
// 5.2.8.9 Queue a task to fire a trusted event named addtrack, that does not bubble and is not cancelable, and that uses the TrackEvent interface, at the AudioTrackList object referenced by the audioTracks attribute on this SourceBuffer object.
@@ -835,7 +835,7 @@ bool SourceBuffer::initializationSegmentReceived(const WebVector<MediaTrackInfo>
// 5.3.8.7.1 Set the selected property on new audio track to true.
videoTrack->setSelected(true);
// 5.3.8.7.2 Set active track flag to true.
- m_activeTrack = true;
+ activeTrack = true;
}
// 5.3.8.8 Add new video track to the videoTracks attribute on this SourceBuffer object.
// 5.3.8.9 Queue a task to fire a trusted event named addtrack, that does not bubble and is not cancelable, and that uses the TrackEvent interface, at the VideoTrackList object referenced by the videoTracks attribute on this SourceBuffer object.
@@ -849,10 +849,10 @@ bool SourceBuffer::initializationSegmentReceived(const WebVector<MediaTrackInfo>
// 5.5 If active track flag equals true, then run the following steps:
// activesourcebuffers.
- if (m_activeTrack) {
+ if (activeTrack) {
// 5.5.1 Add this SourceBuffer to activeSourceBuffers.
// 5.5.2 Queue a task to fire a simple event named addsourcebuffer at activeSourceBuffers
- m_source->setSourceBufferActive(this);
+ m_source->setSourceBufferActive(this, true);
}
// 5.6. Set first initialization segment received flag to true.
« no previous file with comments | « third_party/WebKit/Source/modules/mediasource/SourceBuffer.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698