Closed
Bug 171003
Opened 22 years ago
Closed 22 years ago
when tabbing nav is "all elements", need to hit tab 2x for linked images
Categories
(Core :: DOM: UI Events & Focus Handling, defect)
Core
DOM: UI Events & Focus Handling
Tracking
()
VERIFIED
FIXED
mozilla1.2final
People
(Reporter: bugzilla, Assigned: akkzilla)
References
(Blocks 1 open bug, )
Details
(Keywords: access)
Attachments
(3 files, 3 obsolete files)
802 bytes,
patch
|
akkzilla
:
review+
bryner
:
superreview+
dbaron
:
approval+
|
Details | Diff | Splinter Review |
4.92 KB,
image/gif
|
Details | |
1.68 KB,
text/html
|
Details |
when tabbing nav is "all elements" ("accessibility.tabfocus", 7), i need to hit
tab twice for linked images. this seems to be regression from the fix for bug
140612.
i'll attach a simple test case soon.
not sure if bug 170921 might be related, though.
Comment 1•22 years ago
|
||
This is a major accessibility bug.
Reporter | ||
Comment 2•22 years ago
|
||
1. go to http://hopey.mcom.com/tests/linked-image.html
2. start with focus in the urlbar --hit accel-L if needed.
3. start hitting shift-tab to cycle backwards(*)
* 1st hit: "boring text link" link.
* 2nd hit: the linked image is focused --it becomes faded in appearance-- and if
you bring up the context menu (shift-F10), you'll get one for a linked-image.
* 3rd hit: the linked image is focused again --but it appears *reversed*-- and
if you bring up the context menu (shift-F10), you'll get one for a *link*.
* 4th hit: the document's frame is focused.
(*)for some bizarre reason, going fwd with tab doesn't display this behavior. is
this another image selection issue, perhaps?
Reporter | ||
Comment 3•22 years ago
|
||
the image selection stuff was checked into the trunk around 9/11-12, whereas
akkana's fix for 140612 went in on 9/18. will see how this bug relates...
Reporter | ||
Comment 4•22 years ago
|
||
looking at a trunk build from 9/13, i don't see this bug. when i run the test in
comment 2, when focus is on the linked image, i get the context menu for only a
link (not linked image). and, i need only hit the tab (ie, shift-tab) key once
to move focus away from the linked image.
i'm not sure if this is purely a regression due to bug 140612, or if the fix to
140612 might be exposing a bug in the image selection landing.
mike or simon, would you know how to further diagnose this?
Assignee | ||
Comment 5•22 years ago
|
||
Assignee | ||
Updated•22 years ago
|
Status: NEW → ASSIGNED
Target Milestone: --- → mozilla1.2final
Assignee | ||
Comment 6•22 years ago
|
||
Here's the fix. Seeking review.
Assignee | ||
Comment 7•22 years ago
|
||
Here's the patch including the reindenting for the nesting level that was
removed (harder to read).
Assignee | ||
Comment 8•22 years ago
|
||
Comment on attachment 103779 [details] [diff] [review]
Simple fix, two lines with diff -w
Discussed this with sairuh -- apparently the selection is supposed to be on the
image, not the link containing the image (so the context menu should have both
link and image stuff in it, and the image should appear selected rather than
just outlined).
Attachment #103779 -
Flags: needs-work+
Assignee | ||
Updated•22 years ago
|
Attachment #103784 -
Flags: needs-work+
Reporter | ||
Comment 9•22 years ago
|
||
side note: also see bug 176281, since we don't currently focus unlinked images
in the tabbing cycle.
Assignee | ||
Comment 10•22 years ago
|
||
Comment on attachment 103779 [details] [diff] [review]
Simple fix, two lines with diff -w
It turns out that before my change, we only focused the links anyway, not the
images. So this patch is still relevant, and cures the regression I
introduced. Figuring out who changed this since moz1.0 (which did only focus
links) is a separate issue. Let's cure the regression first. Aaron, can you
review?
Attachment #103779 -
Flags: needs-work+
Assignee | ||
Updated•22 years ago
|
Attachment #103784 -
Flags: needs-work+
Comment 11•22 years ago
|
||
Comment on attachment 103779 [details] [diff] [review]
Simple fix, two lines with diff -w
Makes sense. r=aaronl
Attachment #103779 -
Flags: review+
Comment 12•22 years ago
|
||
Is this a better fix? I think the image map links shouldnt' get focused if you
have that setting where links don't get focus.
else if (nsHTMLAtoms::img==tag) {
- // Images are treated like links for tab focus purposes.
- disabled = !(sTabFocusModel & eTabFocus_linksMask);
- if (!disabled) {
+ if (sTabFocusModel & eTabFocus_linksMask) {
nsCOMPtr<nsIDOMHTMLImageElement> nextImage(do_QueryInterface(child));
nsAutoString usemap;
if (nextImage) {
Assignee | ||
Comment 13•22 years ago
|
||
Yes, much better -- good point, Aaron! Here it is as a patch. Bryner, could
you sr? I'll also attach a test case that includes an imagemap, adapted from
one Aaron sent me.
Assignee | ||
Updated•22 years ago
|
Attachment #103779 -
Attachment is obsolete: true
Attachment #103784 -
Attachment is obsolete: true
Assignee | ||
Comment 14•22 years ago
|
||
Assignee | ||
Comment 15•22 years ago
|
||
Attachment #103769 -
Attachment is obsolete: true
Assignee | ||
Comment 16•22 years ago
|
||
Comment on attachment 103910 [details] [diff] [review]
Aaron's patch: include
r=akkana on Aaron's patch.
Attachment #103910 -
Flags: review+
Comment 17•22 years ago
|
||
Comment on attachment 103910 [details] [diff] [review]
Aaron's patch: include
r=aaronl
Comment 18•22 years ago
|
||
Comment on attachment 103910 [details] [diff] [review]
Aaron's patch: include
sr=bryner
Attachment #103910 -
Flags: superreview+
Comment on attachment 103910 [details] [diff] [review]
Aaron's patch: include
a=dbaron for trunk checkin. It seems like it might be worth a comment as to
why you don't set |disabled| for this case, though.
Attachment #103910 -
Flags: approval+
Assignee | ||
Comment 20•22 years ago
|
||
> It seems like it might be worth a comment as to
> why you don't set |disabled| for this case, though.
Good question -- it wasn't obvious to me either. Turns out that if the code
matches an imagemap, it returns directly from there rather than from the clause
at the end of the loop that checks for !disabled. I've added a comment saying so.
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Reporter | ||
Comment 21•22 years ago
|
||
vrfy'd fixed --no longer get the 2x tabbing strangeness. tested with
2002.10.29.08 comm trunk builds on mac 10.2.1, linux rh7.2 and win2k.
thanks, akkana!
Status: RESOLVED → VERIFIED
Updated•6 years ago
|
Component: Keyboard: Navigation → User events and focus handling
Comment 22•6 years ago
|
||
Keywords: sec508
You need to log in
before you can comment on or make changes to this bug.
Description
•