Bug 43121. Move XUL content model code from RDF DLL to content DLL. r=jst,hyatt; sr=brendan.

git-svn-id: svn://10.0.0.236/trunk@87623 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
waterson%netscape.com
2001-02-22 03:01:34 +00:00
parent f681222363
commit 072b4036bc
190 changed files with 1721 additions and 40178 deletions

View File

@@ -25,6 +25,7 @@
#include "nsIHTMLContentSink.h"
#include "nsIInterfaceRequestor.h"
#include "nsIParser.h"
#include "nsParserUtils.h"
#include "nsICSSStyleSheet.h"
#include "nsICSSLoader.h"
#include "nsICSSLoaderObserver.h"
@@ -4466,39 +4467,6 @@ HTMLContentSink::ProcessMETATag(const nsIParserNode& aNode)
return rv;
}
// Returns PR_TRUE if the language name is a version of JavaScript and
// PR_FALSE otherwise
static PRBool
IsJavaScriptLanguage(const nsString& aName, const char* *aVersion)
{
JSVersion version = JSVERSION_UNKNOWN;
if (aName.EqualsIgnoreCase("JavaScript") ||
aName.EqualsIgnoreCase("LiveScript") ||
aName.EqualsIgnoreCase("Mocha")) {
version = JSVERSION_DEFAULT;
}
else if (aName.EqualsIgnoreCase("JavaScript1.1")) {
version = JSVERSION_1_1;
}
else if (aName.EqualsIgnoreCase("JavaScript1.2")) {
version = JSVERSION_1_2;
}
else if (aName.EqualsIgnoreCase("JavaScript1.3")) {
version = JSVERSION_1_3;
}
else if (aName.EqualsIgnoreCase("JavaScript1.4")) {
version = JSVERSION_1_4;
}
else if (aName.EqualsIgnoreCase("JavaScript1.5")) {
version = JSVERSION_1_5;
}
if (version == JSVERSION_UNKNOWN)
return PR_FALSE;
*aVersion = JS_VersionToString(version);
return PR_TRUE;
}
#ifdef DEBUG
void
HTMLContentSink::ForceReflow()
@@ -4884,7 +4852,7 @@ HTMLContentSink::ProcessSCRIPTTag(const nsIParserNode& aNode)
nsAutoString lang;
GetAttributeValueAt(aNode, i, lang);
isJavaScript = IsJavaScriptLanguage(lang, &jsVersionString);
isJavaScript = nsParserUtils::IsJavaScriptLanguage(lang, &jsVersionString);
}
else if (key.EqualsIgnoreCase("charset")) {
//charset from script charset tag