blob: 4b02a8fd6894da417e9dda5846baa46b8b3ec128 [file] [log] [blame]
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Test that video is rendered after being re-inserted into a document.</title>
<script src=media-file.js></script>
<script>
if (window.testRunner)
testRunner.waitUntilDone();
function seeked()
{
if (window.testRunner)
testRunner.notifyDone();
}
function playing()
{
video.pause();
video.currentTime = 0;
}
function canplaythrough()
{
document.body.removeChild(video);
document.body.offsetLeft;
document.body.appendChild(video);
video.play();
}
function start()
{
video = document.getElementsByTagName('video')[0];
video.src = findMediaFile('video', 'content/test');
video.addEventListener('canplaythrough', canplaythrough);
video.addEventListener('playing', playing);
video.addEventListener('seeked', seeked);
}
</script>
</head>
<body onload="start()">
<video width=320 height=240 ></video>
</body>
</html>