зеркало из https://github.com/mozilla/gecko-dev.git
Bug 596168 - Make non-space characters in the "in foreign content" insertion mode set frameset-ok to not OK. rs=jonas, a=jst.
--HG-- extra : rebase_source : e87024a6536be71b1670cb834e4d675523bb8c93
This commit is contained in:
Родитель
d9758ac3ac
Коммит
541bd617e0
|
@ -853,16 +853,14 @@ public abstract class TreeBuilder<T> implements TokenHandler,
|
|||
needToDropLF = false;
|
||||
}
|
||||
|
||||
if (inForeign) {
|
||||
accumulateCharacters(buf, start, length);
|
||||
return;
|
||||
}
|
||||
// optimize the most common case
|
||||
switch (mode) {
|
||||
case IN_BODY:
|
||||
case IN_CELL:
|
||||
case IN_CAPTION:
|
||||
reconstructTheActiveFormattingElements();
|
||||
if (!inForeign) {
|
||||
reconstructTheActiveFormattingElements();
|
||||
}
|
||||
// fall through
|
||||
case TEXT:
|
||||
accumulateCharacters(buf, start, length);
|
||||
|
@ -919,8 +917,10 @@ public abstract class TreeBuilder<T> implements TokenHandler,
|
|||
* Reconstruct the active formatting
|
||||
* elements, if any.
|
||||
*/
|
||||
flushCharacters();
|
||||
reconstructTheActiveFormattingElements();
|
||||
if (!inForeign) {
|
||||
flushCharacters();
|
||||
reconstructTheActiveFormattingElements();
|
||||
}
|
||||
/*
|
||||
* Append the token's character to the
|
||||
* current node.
|
||||
|
@ -1113,8 +1113,10 @@ public abstract class TreeBuilder<T> implements TokenHandler,
|
|||
* Reconstruct the active formatting
|
||||
* elements, if any.
|
||||
*/
|
||||
flushCharacters();
|
||||
reconstructTheActiveFormattingElements();
|
||||
if (!inForeign) {
|
||||
flushCharacters();
|
||||
reconstructTheActiveFormattingElements();
|
||||
}
|
||||
/*
|
||||
* Append the token's character to the
|
||||
* current node.
|
||||
|
|
|
@ -191,15 +191,13 @@ nsHtml5TreeBuilder::characters(const PRUnichar* buf, PRInt32 start, PRInt32 leng
|
|||
}
|
||||
needToDropLF = PR_FALSE;
|
||||
}
|
||||
if (inForeign) {
|
||||
accumulateCharacters(buf, start, length);
|
||||
return;
|
||||
}
|
||||
switch(mode) {
|
||||
case NS_HTML5TREE_BUILDER_IN_BODY:
|
||||
case NS_HTML5TREE_BUILDER_IN_CELL:
|
||||
case NS_HTML5TREE_BUILDER_IN_CAPTION: {
|
||||
reconstructTheActiveFormattingElements();
|
||||
if (!inForeign) {
|
||||
reconstructTheActiveFormattingElements();
|
||||
}
|
||||
}
|
||||
case NS_HTML5TREE_BUILDER_TEXT: {
|
||||
accumulateCharacters(buf, start, length);
|
||||
|
@ -243,8 +241,10 @@ nsHtml5TreeBuilder::characters(const PRUnichar* buf, PRInt32 start, PRInt32 leng
|
|||
accumulateCharacters(buf, start, i - start);
|
||||
start = i;
|
||||
}
|
||||
flushCharacters();
|
||||
reconstructTheActiveFormattingElements();
|
||||
if (!inForeign) {
|
||||
flushCharacters();
|
||||
reconstructTheActiveFormattingElements();
|
||||
}
|
||||
NS_HTML5_BREAK(charactersloop);
|
||||
}
|
||||
case NS_HTML5TREE_BUILDER_IN_SELECT:
|
||||
|
@ -343,8 +343,10 @@ nsHtml5TreeBuilder::characters(const PRUnichar* buf, PRInt32 start, PRInt32 leng
|
|||
accumulateCharacters(buf, start, i - start);
|
||||
start = i;
|
||||
}
|
||||
flushCharacters();
|
||||
reconstructTheActiveFormattingElements();
|
||||
if (!inForeign) {
|
||||
flushCharacters();
|
||||
reconstructTheActiveFormattingElements();
|
||||
}
|
||||
NS_HTML5_BREAK(charactersloop);
|
||||
}
|
||||
case NS_HTML5TREE_BUILDER_IN_TABLE:
|
||||
|
|
|
@ -11,5 +11,4 @@ var html5Exceptions = {
|
|||
"<!doctype html><summary><article></summary>a" : true, // Bug 596171
|
||||
"<!doctype html><p><figcaption>" : true, // http://www.w3.org/Bugs/Public/show_bug.cgi?id=10589
|
||||
"<!doctype html><figcaption><article></figcaption>a" : true, // http://www.w3.org/Bugs/Public/show_bug.cgi?id=10589
|
||||
"<!doctype html><svg>a</svg><frameset><frame>" : true, // Bug 596168
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче