Bug 406073 - OnMouseOver and OnMouseOut Dysfunctional On Marquee, r=bzbarsky, sr=roc, a=beltzner

This commit is contained in:
martijn.martijn@gmail.com 2007-12-12 06:56:57 -08:00
parent 78d516fdff
commit a57f10c262
4 changed files with 45 additions and 3 deletions

View File

@ -0,0 +1,11 @@
<html class="reftest-wait">
<body style="border:3px solid;" onload="setTimeout(doe, 0)">
<marquee behavior="alternate" scrollamount="100"><span style="background-color: lime;">marquee</span></marquee>
<script>
function doe() {
document.getElementsByTagName('marquee')[0].stop();
document.documentElement.className = "";
}
</script>
</body>
</html>

View File

@ -0,0 +1,23 @@
<html class="reftest-wait">
<body style="border:3px solid;" onload="setTimeout(doe, 0)">
<marquee behavior="alternate" scrollamount="100"><span style="background-color: lime;">marquee</span></marquee>
<script>
function doe() {
document.getElementsByTagName('marquee')[0].stop();
document.getElementsByTagName('marquee')[0].start();
document.getElementsByTagName('marquee')[0].stop();
document.getElementsByTagName('marquee')[0].start();
document.getElementsByTagName('marquee')[0].stop();
document.getElementsByTagName('marquee')[0].start();
document.getElementsByTagName('marquee')[0].stop();
document.getElementsByTagName('marquee')[0].start();
document.getElementsByTagName('marquee')[0].stop();
document.getElementsByTagName('marquee')[0].start();
document.getElementsByTagName('marquee')[0].stop();
document.getElementsByTagName('marquee')[0].start();
document.getElementsByTagName('marquee')[0].stop();
document.documentElement.className = "";
}
</script>
</body>
</html>

View File

@ -509,6 +509,7 @@ random == 403134-1.html 403134-1-ref.html # bug 405377
== 405380-1.html 405380-1-ref.html
== 405577-1.html 405577-1-ref.html
== 405584-1.html 405584-1-ref.html
== 406073-1.html 406073-1-ref.html
== 406484-1.html 406484-1-ref.html
== 406568-1.html 406568-1-ref.html
== 407078-1.html 407078-1-ref.html

View File

@ -358,8 +358,12 @@
<method name="start">
<body>
<![CDATA[
if (this.runId == 0)
this._doMove(false);
if (this.runId == 0) {
var myThis = this;
var lambda = function myTimeOutFunction(){myThis._doMove(false);}
this.runId = window.setTimeout(lambda, this._scrollDelay - this._deltaStartStop);
this._deltaStartStop = 0;
}
]]>
</body>
</method>
@ -367,8 +371,10 @@
<method name="stop">
<body>
<![CDATA[
if (this.runId != 0)
if (this.runId != 0) {
this._deltaStartStop = Date.now()- this._lastMoveDate;
clearTimeout(this.runId);
}
this.runId = 0;
]]>
@ -379,6 +385,7 @@
<parameter name="aResetPosition"/>
<body>
<![CDATA[
this._lastMoveDate = Date.now();
//startNewDirection is true at first load and whenever the direction is changed
if (this.startNewDirection) {