DescriptionPrevent 'removetrack' events from firing when all inband text tracks are removed.
This patch fixes a bug where 'removetrack' events were being fired
when all the inband tracks were being removed. This behavior was trying
to implement the "forget the media element's media-resource-specific
tracks" algorithm, but it wasn't correct.
This patch includes the following changes:
- Renames removeAllInbandTracks() to forgetResourceSpecificTracks()
- Reorganized logic in prepareForLoad() to match the spec order. The
shuffling should not have any user visible behaviour change.
- Added forgetResourceSpecificTracks() calls to other places that
the spec indicates it should run.
- Added code to make sure forgetResourceSpecificTracks() doesn't
trigger 'removetrack' events.
- Converted the existing media/track/track-remove-track.html test
to W3C test & added a new test case that verifies that the event
doesn't fire.
BUG=249427
TEST=Existing LayoutTests still pass. Added a new case to media/track/track-remove-track.html
Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=168357
Patch Set 1 #Patch Set 2 : Fix expectations #
Total comments: 2
Patch Set 3 : Move the inband track removal loop into TextTrackList. #
Total comments: 2
Patch Set 4 : Fix expectations whitespace. #Patch Set 5 : Address CR comment and fix layout test crashes. #Patch Set 6 : Fix compiler errors and rebase #Patch Set 7 : Remove expectations since testharness.js tests don't need them. #Patch Set 8 : Add media file used by test #Patch Set 9 : Add a trackElement error handler to shed some light on trybot errors. #Patch Set 10 : Add video to the document. #Patch Set 11 : Add more logging statements to aid trybot debugging. #Patch Set 12 : Rebase and removed media file. Manually checked in the media file. #Patch Set 13 : Remove console messages #Messages
Total messages: 35 (0 generated)
|