Closed
Bug 304753
Opened 19 years ago
Closed 19 years ago
[FIX]nsImageMap is too eager to invalidate on attribute changes
Categories
(Core :: Layout, defect, P2)
Core
Layout
Tracking
()
RESOLVED
FIXED
mozilla1.9alpha1
People
(Reporter: bzbarsky, Assigned: bzbarsky)
Details
Attachments
(1 file)
|
1.59 KB,
patch
|
jst
:
review+
jst
:
superreview+
|
Details | Diff | Splinter Review |
STEPS TO REPRODUCE: 1) Load https://bugzilla.mozilla.org/attachment.cgi?id=162706 2) Watch it freeze up for 2-3 seconds EXPECTED RESULTS: no freeze The problem is that we rebuild the imagemap on every attr set, which makes the whole thing O(N^2) in the number of <area>s. Since none of the attrs relevant to the functioning of the imagemap are changing, we shouldn't be rebuilding.
| Assignee | ||
Comment 1•19 years ago
|
||
| Assignee | ||
Updated•19 years ago
|
OS: Linux → All
Priority: -- → P2
Hardware: PC → All
Summary: nsImageMap is too eager to invalidate on attribute changes → [FIX]nsImageMap is too eager to invalidate on attribute changes
Target Milestone: --- → mozilla1.9alpha
| Assignee | ||
Updated•19 years ago
|
Attachment #192780 -
Flags: superreview?(jst)
Attachment #192780 -
Flags: review?(jst)
Comment 2•19 years ago
|
||
Comment on attachment 192780 [details] [diff] [review] Proposed patch + if (aContent->IsContentOfType(nsIContent::eHTML) && + (aContent->GetNodeInfo()->Equals(nsHTMLAtoms::area) || + aContent->GetNodeInfo()->Equals(nsHTMLAtoms::a)) && aContent->GetNodeInfo() is a virtual function, you may be better off storing it in a local here. Your call. r+sr=jst either way.
Attachment #192780 -
Flags: superreview?(jst)
Attachment #192780 -
Flags: superreview+
Attachment #192780 -
Flags: review?(jst)
Attachment #192780 -
Flags: review+
| Assignee | ||
Comment 3•19 years ago
|
||
This is 1.9 stuff, and I expect peterv's inlining (and renaming) of nsIContent::NodeInfo() to land in 1.9, hopefully sometime soon. ;)
Comment 4•19 years ago
|
||
(In reply to comment #3) > peterv's inlining (and renaming) of > nsIContent::NodeInfo() That's sicking's, I wouldn't do such crazy things! :-P
| Assignee | ||
Comment 5•19 years ago
|
||
Fixed.
Status: NEW → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•