Closed Bug 474324 Opened 16 years ago Closed 5 years ago

When nodes with no matching insertion point are inserted, binding content isn't dropped

Categories

(Core :: XBL, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED WONTFIX

People

(Reporter: bzbarsky, Unassigned)

Details

Attachments

(3 files)

If a node with a binding has a child and the binding has no insertion point for that child, the binding's content is dropped.

But if such a child is inserted dynamically, we leave the binding content in place (and in fact don't show the new child if it was added at the end, and shows it in the wrong place if it's added somewhere else; the fix for bug 307394 will change the wrong place but it will still be wrong).

This is all pretty broken, in my opinion.  The question is whether we can fix it without breaking various XUL stuff...

Neil, Neil, Jonas, thoughts?  Last I checked the content-dropping lived in a really silly place in initial content setup, so this isn't really all that straightforward to do either.  :(
Attached file reference
Attached file Reftest 1
Attached file Reftest 2
I'm not really eager to mess around with this unless it's a regression or unless there is frontend (firefox or otherwise) that is held back by this.
Once this is fixed we might be able to assert in the seek(nsIContent*) method in nsChildIterator.h that I'm adding in bug 307394.
Oh, sure.  I just ran into it because it triggered asserts I thought I could add...

Note that I will be changing the ContentAppended behavior to be more like ContentInserted in bug 307394.

XBL is now disabled in Firefox (Bug 1583314) and is in the process of being removed from Gecko (Bug 1566221), so closing bugs requesting changes to its implementation as wontfix.

Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: