Video is not started even if play button has been pressed.
[framework/web/webkit-efl.git] / LayoutTests / fast / layers / removed-by-scroll-handler.html
1 <script>
2     if (window.testRunner) {
3         testRunner.waitUntilDone();
4         testRunner.dumpAsText();
5     }
6 </script>
7 <p>
8     Test for <i><a href="http://bugs.webkit.org/show_bug.cgi?id=8360">http://bugs.webkit.org/show_bug.cgi?id=8360</a>
9     Repro crash when onscroll handler deletes the scrolled object</i>.
10 </p>
11 <p>
12     Result: <span id="result">test did not complete.</span>
13 </p>
14 <div id="t" style="overflow: auto; width: 200px; height: 100px;" onscroll="this.parentNode.removeChild(this);handleScroll(0);">
15     <div style="height: 200px;"></div>
16 </div>
17
18 <div style="overflow: auto; width: 200px; height: 100px;" onscroll="this.parentNode.removeChild(this);handleScroll(1);">
19     <div style="height: 200px;"></div>
20     <div id="d"></div>
21 </div>
22
23 <script>
24     var scrolledFirstContainer = false;
25     var scrolledSecondContainer = false;
26
27     document.body.offsetTop; t.scrollTop = 20;
28
29     document.getElementById('d').scrollIntoView();
30     
31     function handleScroll(index)
32     {
33         if (index == 0) scrolledFirstContainer = true;
34         else if (index == 1) scrolledSecondContainer = true;
35         
36         if (scrolledFirstContainer && scrolledSecondContainer) {
37             document.getElementById('result').innerText = "SUCCESS";
38         
39             if (window.testRunner)
40                 testRunner.notifyDone();
41         }
42     }
43 </script>