Dont clear our props if we're not changing owner documents. Bug 335333, r+sr=jst

This commit is contained in:
bzbarsky@mit.edu
2006-04-25 20:03:26 +00:00
parent 7a214013bb
commit 2d07a836c2
3 changed files with 3 additions and 3 deletions

View File

@@ -1782,7 +1782,7 @@ nsGenericElement::BindToTree(nsIDocument* aDocument, nsIContent* aParent,
// Handle a change in our owner document.
if (oldOwnerDocument) {
if (oldOwnerDocument && oldOwnerDocument != newOwnerDocument) {
if (newOwnerDocument && HasProperties()) {
// Copy UserData to the new document.
oldOwnerDocument->CopyUserData(this, newOwnerDocument);