Closed
Bug 565819
Opened 14 years ago
Closed 14 years ago
[FIX]Change RestyleForInsert/Append/Remove to use Element and the new sibling API
Categories
(Core :: Layout, defect)
Tracking
()
RESOLVED
FIXED
mozilla1.9.3a5
People
(Reporter: bzbarsky, Assigned: bzbarsky)
References
Details
Attachments
(1 file, 1 obsolete file)
18.83 KB,
patch
|
Details | Diff | Splinter Review |
Prereq for bug 562700, and slightly cleaner/faster code.
Assignee | ||
Comment 1•14 years ago
|
||
Attachment #445268 -
Flags: review?(dbaron)
Comment on attachment 445268 [details] [diff] [review] Like so nsCSSFrameConstructor.cpp: >- for (PRInt32 index = 0; index < aNewIndexInContainer; ++index) { >+ for (nsIContent* cur = aContainer->GetFirstChild(); >+ cur; >+ cur = cur->GetNextSibling()) { Shouldn't this be |cur != aFirstNewContent| instead of |cur| as the condition? >@@ -11493,38 +11489,47 @@ nsCSSFrameConstructor::RestyleForRemove( >- // restyle the previously-last element child if it is before aOldChild >- for (PRInt32 index = aContainer->GetChildCount() - 1; >- index >= 0; --index) { >- nsIContent *content = aContainer->GetChildAt(index); >+ // restyle the now-last element child if it was before aOldChild >+ reachedFollowingSibling = PR_FALSE; Shouldn't reachedFollowingSibling be initialized to aFollowingSibling != nsnull ? r=dbaron with that
Attachment #445268 -
Flags: review?(dbaron) → review+
Assignee | ||
Comment 3•14 years ago
|
||
> Shouldn't this be |cur != aFirstNewContent| instead of |cur| as the condition? Yes. Good catch. > Shouldn't reachedFollowingSibling be initialized to aFollowingSibling != nsnull You mean == nsnull. Yes.
Assignee | ||
Comment 4•14 years ago
|
||
Attachment #445268 -
Attachment is obsolete: true
Assignee | ||
Comment 5•14 years ago
|
||
Pushed http://hg.mozilla.org/mozilla-central/rev/93be15b7e54e
Status: NEW → RESOLVED
Closed: 14 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Assignee | ||
Updated•14 years ago
|
Target Milestone: --- → mozilla1.9.3a5
You need to log in
before you can comment on or make changes to this bug.
Description
•