540247-1.xhtml (1060B)
1 <?xml version="1.0"?> 2 3 <window id="Test for bug 540247" title="Testcase" class="reftest-wait" 4 xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> 5 6 <script><![CDATA[ 7 document.addEventListener("MozReftestInvalidate", runtest, false); 8 9 function runtest() { 10 // Make sure that the effects of the scroll are painted to the screen before 11 // shrinking the size of the scrolled frame. 12 window.addEventListener("MozAfterPaint", finish, false); 13 var scrollbox = document.getElementById('s'); 14 scrollbox.scrollTo(0, 1000); 15 } 16 17 function finish() { 18 document.getElementById('b').style.minHeight = '100px'; 19 document.documentElement.className = ""; 20 } 21 ]]> 22 </script> 23 24 <scrollbox id="s" style="height: 200px; overflow: scroll;"> 25 <vbox> 26 <vbox style="min-height: 150px; min-width: 200px; background: red;" id="b"/> 27 <vbox style="min-height: 150px; min-width: 200px; background: green;"/> 28 <vbox style="min-height: 150px; min-width: 200px; background: blue;"/> 29 <label value="a"/> 30 </vbox> 31 </scrollbox> 32 33 </window>