Work for bug 33475 - completion of Document-related DOM Level 2 support. Null-checks for the empty document case. The documentElement can now be replaced. Load() no longer takes extra unused argument. r=jst,nisheeth

This commit is contained in:
vidur@netscape.com
2000-06-17 01:46:58 +00:00
parent bef1b5ba58
commit a481900e87
14 changed files with 262 additions and 128 deletions

View File

@@ -1194,11 +1194,15 @@ nsHTMLDocument::ContentInserted(nsIContent* aContainer,
PRInt32 aIndexInContainer)
{
if (nsnull != mNamedItems) {
nsIAtom *name;
PRBool inform = PR_FALSE;
if (aContainer) {
nsIAtom *name;
aContainer->GetTag(name);
inform = (name == nsHTMLAtoms::form);
NS_IF_RELEASE(name);
}
aContainer->GetTag(name);
RegisterNamedItems(aChild, name == nsHTMLAtoms::form);
NS_IF_RELEASE(name);
RegisterNamedItems(aChild, inform);
}
return nsDocument::ContentInserted(aContainer, aChild, aIndexInContainer);