<DIV ONMOUSEOVER="this.innerHTML = ..." ONMOUSEOUT="this.innerHTML = ..." not working properly

VERIFIED DUPLICATE of bug 6316

Status

()

Core
DOM: CSS Object Model
P3
normal
VERIFIED DUPLICATE of bug 6316
18 years ago
17 years ago

People

(Reporter: Martin Honnen, Assigned: joki (gone))

Tracking

({dom1})

Trunk
Future
x86
Other
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

18 years ago
The following sets the innerHTML of the DIV during mouseover and tries to reset
it during mouseout. As long as you mouseover/mouseout only the background all
works correct, but when you try to mouseover the text and out again the text is
not restored and the display flickers when you mouseover the text again.

<div id="aDiv" STYLE="background-color: orange;"
     onmouseover="this.innerHTML = 'touched me !';"
     onmouseout="this.innerHTML = 'touch me !';"
>
touch me !
</div>

Note: I file that on DOM level 1. I know innerHTML is not part of DOM but I
think the same people working on DOM in mozilla also implemented innerHMTL for it.

Here is also a workaround which doesn't use innerHTML and which doesn't have the
problem.

<div id="a2ndDiv" STYLE="background-color: orange;"
     onmouseover="this.firstChild.nodeValue = 'touched me !'"
     onmouseout="this.firstChild.nodeValue = 'touch me !'"
>
touch me !
</div>
(Reporter)

Comment 1

18 years ago
Created attachment 19389 [details]
bug demo (mouseover/mouseout the text of the first div and it is not restored properly)
Reassigning to joki
Assignee: jst → joki

Comment 3

18 years ago
dup of bug 40259?
Fabian.
(Assignee)

Comment 4

18 years ago
This is likely due to mouseover/mouseout state not being maintained correctly 
when the node under the mouse is being destroyed and replaced.  Marking future 
for now.

This bug has been marked "future" because the original netscape engineer
working on this is over-burdened. If you feel this is an error, that you or
another known resource will be working on this bug,or if it blocks your work
in some way -- please attach your concern to the bug for reconsideration.
Status: NEW → ASSIGNED
Target Milestone: --- → Future
Keywords: dom1
Component: DOM Level 1 → DOM Style
Taking QA Contact on all open or unverified DOM Style bugs...
QA Contact: janc → ian

Comment 6

17 years ago
Dup of bug 6316 by way of bug 40249.  (Note: another bug with a similar bug 
number, bug 40259, was mentioned earlier in this bug.)

*** This bug has been marked as a duplicate of 6316 ***
Status: ASSIGNED → RESOLVED
Last Resolved: 17 years ago
Resolution: --- → DUPLICATE

Comment 7

17 years ago
VERIFIED dup
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.