fix 76689. r=harishd sr=blizzard

fix non-ASCII xml element name display in the end tag at xml view source
This commit is contained in:
ftang%netscape.com 2001-05-11 14:39:17 +00:00
Родитель b696e7f9a5
Коммит 81953be03a
2 изменённых файлов: 8 добавлений и 2 удалений

Просмотреть файл

@ -504,7 +504,10 @@ nsresult nsHTMLTokenizer::ConsumeTag(PRUnichar aChar,CToken*& aToken,nsScanner&
result=aScanner.Peek(theNextChar, 1);
if(NS_OK==result) {
if(nsCRT::IsAsciiAlpha(theNextChar)||(kGreaterThan==theNextChar)) {
// xml allow non ASCII tag name, consume as end tag. need to make xml view source work
PRBool isXML=((eXMLText==mDocType) || (eXHTMLText==mDocType));
if(nsCRT::IsAsciiAlpha(theNextChar)||(kGreaterThan==theNextChar)||
(isXML && (! nsCRT::IsAscii(theNextChar)))) {
result=ConsumeEndTag(aChar,aToken,aScanner);
}
else result=ConsumeComment(aChar,aToken,aScanner);

Просмотреть файл

@ -504,7 +504,10 @@ nsresult nsHTMLTokenizer::ConsumeTag(PRUnichar aChar,CToken*& aToken,nsScanner&
result=aScanner.Peek(theNextChar, 1);
if(NS_OK==result) {
if(nsCRT::IsAsciiAlpha(theNextChar)||(kGreaterThan==theNextChar)) {
// xml allow non ASCII tag name, consume as end tag. need to make xml view source work
PRBool isXML=((eXMLText==mDocType) || (eXHTMLText==mDocType));
if(nsCRT::IsAsciiAlpha(theNextChar)||(kGreaterThan==theNextChar)||
(isXML && (! nsCRT::IsAscii(theNextChar)))) {
result=ConsumeEndTag(aChar,aToken,aScanner);
}
else result=ConsumeComment(aChar,aToken,aScanner);