Bug 409111, WRONG_DOCUMENT_ERR on unattached nodes through getBoxObjectFor, r+sr=sicking, a=mtschrep

This commit is contained in:
2008-02-14 12:45:07 -08:00
parent 6b6d2710a7
commit 5054199f7a
6 changed files with 46 additions and 14 deletions

View File

@@ -2123,8 +2123,6 @@ nsGenericElement::UnbindFromTree(PRBool aDeep, PRBool aNullParent)
if (HasAttr(kNameSpaceID_XLink, nsGkAtoms::href)) {
document->ForgetLink(this);
}
document->ClearBoxObjectFor(this);
}
// Unset things in the reverse order from how we set them in BindToTree
@@ -2891,7 +2889,6 @@ nsGenericElement::DestroyContent()
nsIDocument *document = GetOwnerDoc();
if (document) {
document->BindingManager()->ChangeDocumentFor(this, document, nsnull);
document->ClearBoxObjectFor(this);
}
PRUint32 i, count = mAttrsAndChildren.ChildCount();