| OLD | NEW |
| 1 <html> | 1 <html> |
| 2 <script src="../js/resources/js-test-pre.js"></script> | 2 <script src="../js/resources/js-test-pre.js"></script> |
| 3 <body> | 3 <body> |
| 4 <div id="container" style="overflow: auto; width: 500px; height: 500px"> | 4 <div id="container" style="overflow: auto; width: 500px; height: 500px"> |
| 5 <div style="height: 5000px; width: 5000px;"></div> | 5 <div style="height: 5000px; width: 5000px;"></div> |
| 6 </div> | 6 </div> |
| 7 <script> | 7 <script> |
| 8 description('Checks that the scroll event fires on elements asychronously and on
ly once.'); | 8 description('Checks that the scroll event fires on elements asychronously and on
ly once.'); |
| 9 | 9 |
| 10 var eventCount = 0; | 10 var eventCount = 0; |
| (...skipping 23 matching lines...) Expand all Loading... |
| 34 container.addEventListener('scroll', scrollHandler, false); | 34 container.addEventListener('scroll', scrollHandler, false); |
| 35 container.scrollTop = 100; | 35 container.scrollTop = 100; |
| 36 if (eventCount > 0) { | 36 if (eventCount > 0) { |
| 37 testFailed('Scroll event fired synchronously'); | 37 testFailed('Scroll event fired synchronously'); |
| 38 finishJSTest(); | 38 finishJSTest(); |
| 39 } | 39 } |
| 40 container.scrollTop = 200; | 40 container.scrollTop = 200; |
| 41 } | 41 } |
| 42 var jsTestIsAsync = true; | 42 var jsTestIsAsync = true; |
| 43 </script> | 43 </script> |
| 44 <script src="../js/resources/js-test-post.js"></script> | |
| 45 </body> | 44 </body> |
| 46 </html> | 45 </html> |
| OLD | NEW |