| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 | 2 |
| 3 <html> | 3 <html> |
| 4 <head> | 4 <head> |
| 5 <style> | 5 <style> |
| 6 #target { | 6 #target { |
| 7 position: relative; | 7 position: relative; |
| 8 left: 100px; | 8 left: 100px; |
| 9 height: 50px; | 9 height: 50px; |
| 10 width: 50px; | 10 width: 50px; |
| 11 background-color: green; | 11 background-color: green; |
| 12 -webkit-transition-property: left; | 12 -webkit-transition-property: left; |
| 13 -webkit-transition-duration: 4s; | 13 -webkit-transition-duration: 4s; |
| 14 -webkit-transition-timing-function: linear; | 14 -webkit-transition-timing-function: linear; |
| 15 -webkit-transition-delay: 1s; | 15 -webkit-transition-delay: 1s; |
| 16 } | 16 } |
| 17 | 17 |
| 18 #target.moved { | 18 #target.moved { |
| 19 left: 200px; | 19 left: 200px; |
| 20 } | 20 } |
| 21 </style> | 21 </style> |
| 22 <script src="resources/transition-test-helpers.js"></script> | 22 <script src="resources/transition-test-helpers.js"></script> |
| 23 <script> | 23 <script> |
| 24 function endTest() { | 24 function endTest() { |
| 25 if (window.testRunner) { | 25 if (window.testRunner) { |
| 26 var target = document.getElementById('target'); | 26 var target = document.getElementById('target'); |
| 27 internals.pauseTransitionAtTimeOnElement("left", 2.0, target); | 27 internals.pauseAnimations(2); |
| 28 var left = window.getComputedStyle(target).left; | 28 var left = window.getComputedStyle(target).left; |
| 29 var result = "PASS"; | 29 var result = "PASS"; |
| 30 if (left != "125px") { | 30 if (left != "125px") { |
| 31 result = "FAIL - expected 125px got " + left; | 31 result = "FAIL - expected 125px got " + left; |
| 32 } | 32 } |
| 33 document.getElementById('result').innerHTML = "<p>" + result + "</p>"; | 33 document.getElementById('result').innerHTML = "<p>" + result + "</p>"; |
| 34 testRunner.notifyDone(); | 34 testRunner.notifyDone(); |
| 35 } | 35 } |
| 36 } | 36 } |
| 37 | 37 |
| (...skipping 15 matching lines...) Expand all Loading... |
| 53 only there to jump to a particular time in a running transition. | 53 only there to jump to a particular time in a running transition. |
| 54 Tests bug <a href="https://bugs.webkit.org/show_bug.cgi?id=22368">22368</a> | 54 Tests bug <a href="https://bugs.webkit.org/show_bug.cgi?id=22368">22368</a> |
| 55 </p> | 55 </p> |
| 56 | 56 |
| 57 <div id="target"></div> | 57 <div id="target"></div> |
| 58 | 58 |
| 59 <div id="result"></div> | 59 <div id="result"></div> |
| 60 | 60 |
| 61 </body> | 61 </body> |
| 62 </html> | 62 </html> |
| OLD | NEW |