Closed
Bug 12232
Opened 25 years ago
Closed 25 years ago
[EVENTTARG] events going to wrong element: visibility=hidden
Categories
(Core :: DOM: UI Events & Focus Handling, defect, P3)
Core
DOM: UI Events & Focus Handling
Tracking
()
VERIFIED
FIXED
M15
People
(Reporter: dbaron, Assigned: dbaron)
References
Details
(Keywords: testcase)
Attachments
(2 files)
This is the second of two bugs I am filing on events going to the wrong
elements. Bug 1413 also deals with this problem (for floats), bug 12231 for
negative margins, and this one for visibility: hidden. They are related,
but probably separate. There may be other existing bugs too...
DESCRIPTION: Frequently, a group of elements overlap and the author sets the
visibility property dynamically so that only one is shown. (I think) the events
over that space should go to the one that is visible. Otherwise, strange things
could happen.
STEPS TO REPRODUCE:
* Load attached testcase
* click on paragraph
ACTUAL RESULTS: The alert says: "You clicked on paragraph one." (Once
bug 12231 is fixed, it will say three instead of one.)
EXPECTED RESULTS: The alert should say: "You clicked on paragraph two."
DOES NOT WORK CORRECTLY ON:
* Linux, apprunner, 1999-08-16-08-M9
Assignee | ||
Updated•25 years ago
|
Summary: events going to wrong element: negative margins → events going to wrong element: visibility=hidden
Whiteboard: [TESTCASE]
Assignee | ||
Comment 1•25 years ago
|
||
Updated•25 years ago
|
Status: NEW → ASSIGNED
Target Milestone: M12
Assignee | ||
Updated•25 years ago
|
OS: Linux → All
Hardware: PC → All
Assignee | ||
Comment 2•25 years ago
|
||
ALSO DOES NOT WORK CORRECTLY ON:
* Windows, apprunner, 1999-08-24-09-M10
Marking All/All.
Comment 4•25 years ago
|
||
Doesn't this imply that 'visibility' is changing the z-index?
(Note that certainly in the case of :hover, we want the event to go to all of
the elements under the cursor, not just the visible one(s) or the top most one.)
Hmm...
Assignee | ||
Comment 5•25 years ago
|
||
I disagree with both statements...
It just means events only go to things that are visible.
Furthermore, I think :hover should match the topmost element being hovered and
all its ancestors. With perhaps something like what Ian said for tables... (I
think. See the :hover bug for better thought out comments.)
Comment 6•25 years ago
|
||
:hover should definitely apply to elements with visible:hidden, otherwise
pages using things like the following would not work:
http://www.bath.ac.uk/%7Epy8ieh/internet/projects/mozilla/visible-dynamic.html
An example of how this could be used: overlap a hidden, absolutely positioned
element on top of another element, and when you hover over it make it visible.
Simple and easy tooltips.
We currently bubble events up the DOM, so that a click on an element is sent
up all its parents if it is not grabbed along the way. (Right?)
If the event gets to the top of the tree (the canvas), then (I guess!) we just
drop it. Right?
I suggest what we do is that we send the event to the top most element, and if
it bubbles all the way to the canvas we then try to send it to the element
underneath it (assuming of course that it is not an ancestor of the first),
and if it still bubbles all the way up to the canvas (or up to a common
ancestor, anyway) then we try again with the next element, and so on.
That way events would not get lost, but would only get sent to one element.
Hmm. I have already suggested this before, in bug 5693 (the :hover bug).
I Can't see it is sane that hidden element get events. Is that
*expicitly* stated by the standard?
The tooltip exampel can be solved by seting the tooltip visible
on an mouseover event on the item belov (Who is explaind by the
tooltip).
Event going to hidden element vill mess upp common practise. If
one have multiple dives with links on top off eachother for fast
switching (by swiching visability) You definitly want the visably
div get the event only. If the user click beside one link it wold
be *verry* confusing if an hidden link in another div is called.
Just user input /Lars
Assignee | ||
Comment 8•25 years ago
|
||
There is no W3C draft or recommendation, or any other standard, that, to my
knowledge, says *anything* about when an element should receieve events. (With
the possible exception of some very vague comments in HTML.) This will result
in huge inconsistencies between implementations.
IMO, either DOM2 should specify this in terms of the CSS rendering model or CSS
should specify it. (Probably DOM2 should as an informative statement, and CSS3
should normatively.)
Updated•25 years ago
|
Target Milestone: M12 → M14
Comment 9•25 years ago
|
||
Once again cool but will also have to wait.
Assignee | ||
Updated•25 years ago
|
Summary: events going to wrong element: visibility=hidden → [EVENTTARG]events going to wrong element: visibility=hidden
Comment 10•25 years ago
|
||
*** Bug 23433 has been marked as a duplicate of this bug. ***
Updated•25 years ago
|
Summary: [EVENTTARG]events going to wrong element: visibility=hidden → [EVENTTARG] events going to wrong element: visibility=hidden
Target Milestone: M14 → M16
Comment 11•25 years ago
|
||
Moving M16.
Comment 12•25 years ago
|
||
Bulk moving [testcase] code to new testcase keyword. Sorry for the spam!
Keywords: testcase
Comment 13•25 years ago
|
||
*** Bug 25075 has been marked as a duplicate of this bug. ***
Comment 14•25 years ago
|
||
Comment 15•25 years ago
|
||
*** Bug 25957 has been marked as a duplicate of this bug. ***
Assignee | ||
Comment 16•25 years ago
|
||
I have this bug fixed in my tree (modulo another bug on the test page with
selection, that I'll look at tomorrow). Stealing bug...
Assignee: joki → dbaron
Status: ASSIGNED → NEW
Updated•25 years ago
|
Whiteboard: [TESTCASE]
Assignee | ||
Updated•25 years ago
|
Status: NEW → ASSIGNED
Assignee | ||
Updated•25 years ago
|
Target Milestone: M16 → M15
Comment 17•25 years ago
|
||
*** Bug 25357 has been marked as a duplicate of this bug. ***
Comment 18•25 years ago
|
||
*** Bug 11333 has been marked as a duplicate of this bug. ***
Comment 19•25 years ago
|
||
*** Bug 23477 has been marked as a duplicate of this bug. ***
Comment 20•25 years ago
|
||
*** Bug 30056 has been marked as a duplicate of this bug. ***
Comment 21•25 years ago
|
||
*** Bug 30056 has been marked as a duplicate of this bug. ***
Assignee | ||
Comment 22•25 years ago
|
||
Fix checked in 2000-03-21 18:39-18:43 PST.
Status: ASSIGNED → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Comment 23•25 years ago
|
||
The bug reappears in the build around March 20.
Base on the example, click on the layer results in message: "you clicked on
paragraph three.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 24•25 years ago
|
||
Marking fixed again. Reopening a bug that was noted as "Fix checked in
2000-03-21" based on a March 20 build is probably not the best thing to do...
Status: REOPENED → RESOLVED
Closed: 25 years ago → 25 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 25•25 years ago
|
||
*** Bug 35474 has been marked as a duplicate of this bug. ***
Assignee | ||
Comment 26•25 years ago
|
||
*** Bug 37087 has been marked as a duplicate of this bug. ***
Comment 27•24 years ago
|
||
Mass update: changing qacontact to ckritzer@netscape.com
QA Contact: janc → ckritzer
Comment 29•24 years ago
|
||
Reassigning QA Contact for all open and unverified bugs previously under Lorca's
care to Gerardo as per phone conversation this morning.
QA Contact: lorca → gerardok
Updated•6 years ago
|
Component: Event Handling → User events and focus handling
You need to log in
before you can comment on or make changes to this bug.
Description
•