Closed Bug 448987 Opened 11 years ago Closed 11 years ago

<area shape="default"> does not render focus outline

Categories

(Core :: Layout, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla1.9.1a2

People

(Reporter: mats, Assigned: mats)

References

Details

(Keywords: html4, testcase)

Attachments

(3 files, 1 obsolete file)

Attached file Testcase
<area shape="default"> does not render focus outline

STEPS TO REPRODUCE
1. load the attached testcase

HTML4 says:
"default: Specifies the entire region."
http://www.w3.org/TR/html401/struct/objects.html#edef-AREA

My interpretation is that we should render a focus outline just inside
the image edge. FWIW, that's what Opera does.
Attached patch reftest.diffSplinter Review
Attached patch Patch rev. 1 (obsolete) — Splinter Review
Pretty straight forward: changing some methods to take a nsIFrame*
instead of nsPresContext* (hopefully this will aid fixing the bug
we have with multiple images using the same map too),
the bug fix is in DefaultArea::Draw() and DefaultArea::GetRect()
which were empty.  I also made nsImageMap::GetBoundsForAreaContent()
more robust (it implements the nsIImageMap interface method).

BTW, the reftest reference will need adjusting once bug 362731
is fixed, see bug 362731 comment 5 regarding the error.
Attachment #332175 - Flags: superreview?(roc)
Attachment #332175 - Flags: review?(roc)
No change, just updated to tip due to the conflict with bug 448860.
Attachment #332175 - Attachment is obsolete: true
Attachment #332203 - Flags: superreview?(roc)
Attachment #332203 - Flags: review?(roc)
Attachment #332175 - Flags: superreview?(roc)
Attachment #332175 - Flags: review?(roc)
Blocks: 443215
No longer blocks: 443215
Comment on attachment 332203 [details] [diff] [review]
Patch rev. 2 (updated to tip)

Seems like this code could be cleaned up a lot, e.g. by refactoring the Draw code.
Attachment #332203 - Flags: superreview?(roc)
Attachment #332203 - Flags: superreview+
Attachment #332203 - Flags: review?(roc)
Attachment #332203 - Flags: review+
This check-in may have started qm-win2k3-unittest-hw burning. Can you please look at the logs and see if it's related?
Filed bug 449611 for the issue.
It's a make.exe crash, so I think it's unrelated.
http://hg.mozilla.org/mozilla-central/index.cgi/rev/d8f62778e9e4
http://hg.mozilla.org/mozilla-central/index.cgi/rev/06820914768f
http://hg.mozilla.org/mozilla-central/index.cgi/rev/d6a0a4fca081

The reftest needs privileges so it depends on bug 448676.
I forgot and landed it, but I have commented it out in reftest.list now.

-> FIXED
Status: NEW → RESOLVED
Closed: 11 years ago
Depends on: 448676
Flags: in-testsuite?
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9.1a2
Depends on: 527804
You need to log in before you can comment on or make changes to this bug.