Update web-platform-tests to revision 4100d1d51b885185c50902397f7d203d89efc24c

This commit is contained in:
WPT Sync Bot 2019-06-16 10:25:29 +00:00
parent fd174c54ef
commit 35b828da75
91 changed files with 1843 additions and 298 deletions

View file

@ -10,12 +10,12 @@
}
.cue {
position: absolute;
top: 48px;
top: 30px;
left: 0px;
font-family: sans-serif;
background: green;
color: rgba(255, 255, 255, 1);
font-size: 12px;
padding: 0px 2px;
font-size: 7.5px;
}
</style>
<div class="container">
@ -26,4 +26,4 @@
</video>
<span class="cue">Bear is Coming!!!!!</span>
</div>
</html>
</html>

View file

@ -21,4 +21,4 @@ track.addCue(cue);
track.mode = "showing";
video.src = getVideoURI("/media/test");
</script>
</html>
</html>

View file

@ -15,9 +15,11 @@ var cue = new VTTCue(0, 3, "cue 2");
cue.line = -2;
track.addCue(cue);
track.mode = "showing";
video.onloadeddata = function() {
video.play();
video.onplaying = function() {
video.onplaying=null;
video.pause();
takeScreenshot();
};
</script>
</html>
</html>

View file

@ -11,20 +11,16 @@
// Add two cues, where the first cue ends before the second.
var video = document.querySelector("video");
var track = video.addTextTrack("captions");
track.addCue(new VTTCue(0, 1, "cue 1"));
track.addCue(new VTTCue(0, 3, "cue 2"));
let cue1 = new VTTCue(-1, 1, "cue 1");
track.addCue(cue1);
// As video's duration is 10s, it ensures that this cue would always be displayed.
track.addCue(new VTTCue(0, 10, "cue 2"));
track.mode = "showing";
video.onloadeddata = function() {
// Double nesting of requestAnimationFrame to
// make sure cue layout and paint happens.
window.requestAnimationFrame(function() {
window.requestAnimationFrame(function() {
// Seek past the end of the first cue. The second cue should not move.
video.currentTime = 2;
video.onseeked = function() { takeScreenshot(); };
});
});
video.play();
cue1.onexit = () => {
cue1.onexit = null;
video.pause();
takeScreenshot();
};
</script>
</html>
</html>