Changeset 70094 in webkit
- Timestamp:
- Oct 19, 2010 3:16:12 PM (13 years ago)
- Location:
- trunk/WebCore
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebCore/ChangeLog
r70093 r70094 1 2010-10-19 James Simonsen <simonjam@chromium.org> 2 3 Reviewed by Adam Barth. 4 5 Add "in select" insertion mode to parser. 6 7 This was added to the spec in: 8 http://html5.org/tools/web-apps-tracker?from=5520&to=5522 9 10 And as a result of: 11 http://www.w3.org/Bugs/Public/show_bug.cgi?id=10314 12 13 https://bugs.webkit.org/show_bug.cgi?id=47706 14 15 No new tests. Open to ideas. 16 17 * html/parser/HTMLElementStack.cpp: Added "in select" mode. 18 (WebCore::HTMLNames::isSelectScopeMarker): Ditto. 19 (WebCore::HTMLElementStack::inSelectScope): Ditto. 20 * html/parser/HTMLElementStack.h: Ditto. 21 * html/parser/HTMLTreeBuilder.cpp: 22 (WebCore::HTMLTreeBuilder::processStartTag): Use "in select" instead of "in table." 23 (WebCore::HTMLTreeBuilder::processEndTag): Ditto. 24 1 25 2010-10-19 Jeremy Orlow <jorlow@chromium.org> 2 26 -
trunk/WebCore/html/parser/HTMLElementStack.cpp
r67373 r70094 114 114 } 115 115 116 inline bool isSelectScopeMarker(Element* element) 117 { 118 return !element->hasTagName(optgroupTag) 119 && !element->hasTagName(optionTag); 120 } 121 116 122 } 117 123 … … 485 491 // FIXME: Is localName() right for non-html elements? 486 492 return inButtonScope(tagName.localName()); 493 } 494 495 bool HTMLElementStack::inSelectScope(const AtomicString& targetTag) const 496 { 497 return inScopeCommon<isSelectScopeMarker>(m_top.get(), targetTag); 498 } 499 500 bool HTMLElementStack::inSelectScope(const QualifiedName& tagName) const 501 { 502 // FIXME: Is localName() right for non-html elements? 503 return inSelectScope(tagName.localName()); 487 504 } 488 505 -
trunk/WebCore/html/parser/HTMLElementStack.h
r67372 r70094 118 118 bool inButtonScope(const AtomicString& tagName) const; 119 119 bool inButtonScope(const QualifiedName&) const; 120 bool inSelectScope(const AtomicString& tagName) const; 121 bool inSelectScope(const QualifiedName&) const; 120 122 121 123 bool hasOnlyHTMLElementsInScope() const; -
trunk/WebCore/html/parser/HTMLTreeBuilder.cpp
r69170 r70094 1423 1423 || token.name() == textareaTag) { 1424 1424 parseError(token); 1425 if (!m_tree.openElements()->in TableScope(selectTag)) {1425 if (!m_tree.openElements()->inSelectScope(selectTag)) { 1426 1426 ASSERT(isParsingFragment()); 1427 1427 return; … … 2280 2280 } 2281 2281 if (token.name() == selectTag) { 2282 if (!m_tree.openElements()->in TableScope(token.name())) {2282 if (!m_tree.openElements()->inSelectScope(token.name())) { 2283 2283 ASSERT(isParsingFragment()); 2284 2284 parseError(token);
Note: See TracChangeset
for help on using the changeset viewer.