Move CreateCDATASection, CreateProcessingInstruction, and CreateEntityReference

up to nsDocument so they're available in XHTML documents.  Bug 69840, r+sr=jst


git-svn-id: svn://10.0.0.236/trunk@153443 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
bzbarsky%mit.edu
2004-03-02 22:39:46 +00:00
parent 67ff3ea238
commit ee0a2e7a8a
4 changed files with 52 additions and 69 deletions

View File

@@ -1426,6 +1426,10 @@ nsHTMLDocument::CreateProcessingInstruction(const nsAString& aTarget,
const nsAString& aData,
nsIDOMProcessingInstruction** aReturn)
{
if (IsXHTML()) {
return nsDocument::CreateProcessingInstruction(aTarget, aData, aReturn);
}
// There are no PIs for HTML
*aReturn = nsnull;
@@ -1436,6 +1440,10 @@ NS_IMETHODIMP
nsHTMLDocument::CreateCDATASection(const nsAString& aData,
nsIDOMCDATASection** aReturn)
{
if (IsXHTML()) {
return nsDocument::CreateCDATASection(aData, aReturn);
}
// There are no CDATASections in HTML
*aReturn = nsnull;
@@ -1446,6 +1454,10 @@ NS_IMETHODIMP
nsHTMLDocument::CreateEntityReference(const nsAString& aName,
nsIDOMEntityReference** aReturn)
{
if (IsXHTML()) {
return nsDocument::CreateEntityReference(aName, aReturn);
}
// There are no EntityReferences in HTML
*aReturn = nsnull;