blob: 7a174e35ac8845e15dbe5cc00306ff3bd96de1e7 [file] [log] [blame]
<!doctype html>
<html>
<head>
<title>controls after unload</title>
<script src=media-file.js></script>
</head>
<body>
<video controls></video>
<script>
if (window.testRunner)
testRunner.waitUntilDone();
var video = document.querySelector("video");
video.src = findMediaFile("video", "content/test");
// Get the video into a playing state at currentTime > 0.
video.autoplay = true;
video.addEventListener("playing", function()
{
video.currentTime = 3;
video.addEventListener("seeked", function()
{
// Remove src and reload. The controls should reset and not
// show a playing state or currentTime > 0.
video.removeAttribute("src");
video.load();
video.addEventListener("emptied", function()
{
if (window.testRunner)
testRunner.notifyDone();
});
});
});
</script>
</body>
</html>