blob: 3b4c3542a92ec0b42a5353ba1cbef8d6cdc9f886 [file] [log] [blame]
<!DOCTYPE html>
<title>Add a track and change its mode through JS</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<video>
<source src="/media/test.mp4" type="video/mp4">
<source src="/media/test.ogv" type="video/ogg">
</video>
<script>
test(function() {
var video = document.querySelector('video');
var track = video.addTextTrack('captions', 'English', 'en');
track.addCue(new VTTCue(0.0, 10.0, 'wow wow'));
track.mode = 'showing';
});
</script>