Rubber-stamped by Brady Eidson.
[webbrowser.git] / LayoutTests / animations / state-at-end-event-transform.html
blobf1e5b6b885446d7e10a23086e52393b8c0771cc1
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
2 "http://www.w3.org/TR/html4/loose.dtd">
4 <html lang="en">
5 <head>
6 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
7 <style>
8 #container {
9 position: relative;
10 width: 400px;
11 height: 100px;
12 border: 1px solid black;
15 .box {
16 position: absolute;
17 width: 100px;
18 height: 100px;
19 background-color: green;
22 .indicator {
23 left: 0;
24 top: 0;
25 background-color: red;
28 #container.moved .hardware {
29 -webkit-animation: move 300ms linear;
32 .hardware {
33 -webkit-transform: translate3d(0, 0, 0);
36 @-webkit-keyframes move {
37 from { -webkit-transform: translate3d(0, 0, 0); }
38 to { -webkit-transform: translate3d(300px, 0, 0); }
40 </style>
41 <script type="text/javascript" charset="utf-8">
43 function testEnded()
45 if (window.layoutTestController)
46 layoutTestController.notifyDone();
49 function startTest()
51 if (window.layoutTestController)
52 layoutTestController.waitUntilDone();
54 document.getElementById('tester').addEventListener('webkitAnimationEnd', testEnded, false);
55 document.getElementById('container').className = 'moved';
58 window.addEventListener('load', startTest, false);
59 </script>
60 </head>
61 <body>
63 <p>At the end of the test the green box should obscure the red box.</p>
64 <div id="container">
65 <div class="indicator box"></div>
66 <div id="tester" class="hardware box"></div>
67 </div>
69 <div id="result">
70 </div>
72 </body>
73 </html>