Closed
Bug 313844
Opened 20 years ago
Closed 17 years ago
Mouseout and mousein fire multiple times on an input element
Categories
(Core :: DOM: Events, defect)
Tracking
()
RESOLVED
WORKSFORME
People
(Reporter: codynotes, Unassigned)
References
()
Details
Attachments
(1 file)
|
636 bytes,
text/html
|
Details |
User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.7.12) Gecko/20050915 Firefox/1.0.7
Build Identifier: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.7.12) Gecko/20050915 Firefox/1.0.7
A spurious mouseout event followed by an immediate mousein event will fires for input elements of the type text, password, or file. When margins and padding are added to the input element, it appears that the extra mouseout fires when the mouse moves from the input element's padding to the actual text-input area itself, and is followed by another immediate mousein. Please see the attached URL for a demonstration of this behavior.
I've reproduced this bug with 1.0.7 and 1.5 on OS X 1.4.2, as well as with 1.0.7 on Windows XP Professional SP2.
Reproducible: Always
Steps to Reproduce:
1. Create a page with an text input element on it.
2. Perform some behavior upon mousein and mouseout on the element.
Actual Results:
The behavior that should be performed on mousein and mouseout will ocurr unnecessarily in the middle of the element when the mouse doesn't actually leave or reenter the element's bounds.
Expected Results:
The mousein and mouseout events should fire once each, upon entering and leaving the element's bounds.
The behavior is correct with input elements with type radio, checkbox, button, submit, and reset.
Updated•20 years ago
|
Assignee: nobody → events
Component: General → DOM: Events
Keywords: testcase
OS: MacOS X → All
Product: Firefox → Core
QA Contact: general → ian
Version: unspecified → Trunk
Comment 1•20 years ago
|
||
I'm seeing this also with current trunk build.
Yeah, the testcase is indeed a 404. That's what happens when the bug report is submitted in 2005 and it takes two and a half years before someone looks at it. That's an amazing turnaround time.
I'll see if I can find the original testcase file I had put up.
I just recreated what I assume was my testcase, and the problem still appears to occur in: Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv:1.8.1.11) Gecko/20071127 Firefox/2.0.0.11.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>Test</title>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<script type="text/javascript">
function printMessage(message)
{
document.getElementById('message').innerHTML += message + "<br />";
}
</script>
</head>
<body>
<p><input type="text" onmouseover="printMessage('mouseover');" onmouseout="printMessage('mouseout');" style="margin: 20px; padding: 20px; background-color: red; border: 10px solid blue;" /></p>
<div id="message"></div>
</body>
</html>
If you move the mouse from top to bottom over the input control once, you get the following series of events:
mouseover
mouseout
mouseover
mouseout
mouseover
mouseout
Comment 5•17 years ago
|
||
Thanks for reviving the testcase!
I can see the bug on branch, but with the latest trunk build, the bug seems to be worksforme.
Would you be willing to also test this with current trunk build?
http://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/latest-trunk/
Comment 6•17 years ago
|
||
WFM also Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9b2) Gecko/2007121016 Firefox/3.0b2
Comment 7•17 years ago
|
||
Ok, I'll just mark it worksforme then.
Status: UNCONFIRMED → RESOLVED
Closed: 17 years ago
Resolution: --- → WORKSFORME
Comment 8•17 years ago
|
||
Fixed most probably by bug 369644.
You need to log in
before you can comment on or make changes to this bug.
Description
•