blob: d6bdff48aeab5cae05d3ab3aa0280c01a2433b63 [file] [log] [blame]
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style>
body {
margin: 0;
}
div {
position: relative;
left: 100px;
height: 200px;
width: 200px;
background-color: red;
-webkit-animation-duration: 5s;
-webkit-animation-timing-function: linear;
}
@-webkit-keyframes anim {
from { left: 10px; }
40% { left: 30px; }
60% { left: 15px; }
to { left: 20px; }
}
</style>
<script src="animation-test-helpers.js" type="text/javascript" charset="utf-8"></script>
<script type="text/javascript" charset="utf-8">
if (window.layoutTestController)
layoutTestController.waitUntilDone();
function animationStarted()
{
if (window.layoutTestController) {
if (!layoutTestController.pauseAnimationAtTimeOnElementWithId("anim", 3, "box"))
throw("Animation is not running");
layoutTestController.notifyDone();
}
}
function startTest()
{
document.getElementById("box").style.webkitAnimationName = "anim";
waitForAnimationToStart(document.getElementById('box'), animationStarted);
}
</script>
</head>
<body onload="startTest()">
<h1>Test for DRT pauseAnimationAtTimeOnElementWithId() API on animations with multiple keyframes</h1>
<div id="box">
</div>
</body>
</html>