nsHTMLMapElement::SetDocument(nsIDocument* aDocument, PRBool aDeep)
nsHTMLMapElement::SetDocument(nsIDocument* aDocument, PRBool aDeep, PRBool aCompileEventHandlers)
nsHTMLMapElement::SetDocument(nsIDocument* aDocument, PRBool aDeep){  nsresult rv;    if (nsnull != mInner.mDocument) {    nsCOMPtr<nsIHTMLDocument> htmlDoc;        rv = mInner.mDocument->QueryInterface(kIHTMLDocumentIID,                                           getter_AddRefs(htmlDoc));    if (NS_OK == rv) {      htmlDoc->RemoveImageMap(this);    }  }  rv = mInner.SetDocument(aDocument, aDeep);  if (NS_SUCCEEDED(rv) && (nsnull != aDocument)) {    nsCOMPtr<nsIHTMLDocument> htmlDoc;        rv = aDocument->QueryInterface(kIHTMLDocumentIID,                                    getter_AddRefs(htmlDoc));    if (NS_OK == rv) {      htmlDoc->AddImageMap(this);    }  }    return rv;}