Closed
Bug 314776
Opened 19 years ago
Closed 19 years ago
[FIX]Content is rendered twice when using JS methods appendChild, insertBefore, replaceChild
Categories
(Core :: Layout, defect, P1)
Core
Layout
Tracking
()
RESOLVED
FIXED
mozilla1.9alpha1
People
(Reporter: mjuhos, Assigned: bzbarsky)
References
Details
(Keywords: testcase)
Attachments
(4 files)
466 bytes,
text/html
|
Details | |
408 bytes,
text/html
|
Details | |
466 bytes,
text/html
|
Details | |
8.05 KB,
patch
|
dbaron
:
review+
dbaron
:
superreview+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; cs; rv:1.8) Gecko/20051025 Firefox/1.5 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; cs; rv:1.8) Gecko/20051025 Firefox/1.5 There is problem with display hidden DIV element and setting STYLE to this element and than with add this content to HTML code - it will be rendered twice. Reproducible: Always Steps to Reproduce: See and try test cases. Actual Results: Content is rendered twice. Expected Results: Content is rendered one time.
Reporter | ||
Comment 1•19 years ago
|
||
Reporter | ||
Comment 2•19 years ago
|
||
Reporter | ||
Comment 3•19 years ago
|
||
Assignee | ||
Updated•19 years ago
|
Component: General → Layout
Product: Firefox → Core
QA Contact: general → layout
Version: unspecified → Trunk
Assignee | ||
Comment 4•19 years ago
|
||
This is a followup to bug 312695. What's happening here, of course, is that the BindToTree causes a style reresolve and sync frame construction, and then we notify on the content we just bound. The only way I see of dealing with this is to make the style reresolve from BindToTree async. This basically means doing solution 2 from bug 312695 comment 8. The problem would, unfortunately, still be reproducible if the stuff we're binding includes scripts that do certain things. But given all the ways in which scripts being inserted can screw with content prior to the notification, I think we can live with that for the nonce. In particular, with scripts it's possible to get content doubling without any involvement from style at all.
Assignee: nobody → bzbarsky
Status: UNCONFIRMED → NEW
Ever confirmed: true
OS: Windows XP → All
Priority: -- → P1
Hardware: PC → All
Target Milestone: --- → mozilla1.9alpha
Assignee | ||
Comment 5•19 years ago
|
||
This just makes all of our style changes go through the same async restyle mechanism.
Attachment #201907 -
Flags: superreview?(dbaron)
Attachment #201907 -
Flags: review?(dbaron)
Assignee | ||
Updated•19 years ago
|
Summary: Content is rendered twice when using JS methods appendChild, insertBefore, replaceChild → [FIx]Content is rendered twice when using JS methods appendChild, insertBefore, replaceChild
Assignee | ||
Updated•19 years ago
|
Summary: [FIx]Content is rendered twice when using JS methods appendChild, insertBefore, replaceChild → [FIX]Content is rendered twice when using JS methods appendChild, insertBefore, replaceChild
Comment on attachment 201907 [details] [diff] [review] Proposed patch Are there bugs filed on: * preventing this kind of problem in general? * asserting when this kind of thing happens? (Could I add this case to bug 310985 somehow?) Right most of the time really isn't good enough -- we need to figure out how to do this stuff correctly.
Attachment #201907 -
Flags: superreview?(dbaron)
Attachment #201907 -
Flags: superreview+
Attachment #201907 -
Flags: review?(dbaron)
Attachment #201907 -
Flags: review+
Assignee | ||
Comment 7•19 years ago
|
||
Fixed. (In reply to comment #6) > * preventing this kind of problem in general? > * asserting when this kind of thing happens? (Could I add this case to bug > 310985 somehow?) Filed bug 315306.
Status: NEW → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Blocks: 312695
You need to log in
before you can comment on or make changes to this bug.
Description
•