Changeset 147185 in webkit
- Timestamp:
- Mar 28, 2013 5:13:05 PM (11 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r147183 r147185 1 2013-03-28 Rafael Weinstein <rafaelw@chromium.org> 2 3 [HTMLTemplateElement] <template> should be able to be a foster parent 4 https://bugs.webkit.org/show_bug.cgi?id=113541 5 6 Reviewed by Eric Seidel. 7 8 * html5lib/resources/template.dat: 9 1 10 2013-03-28 Tony Chang <tony@chromium.org> 2 11 -
trunk/LayoutTests/html5lib/resources/template.dat
r146923 r147185 1147 1147 | <template> 1148 1148 | content 1149 | "Foo" 1149 1150 | <table> 1150 | "Foo"1151 1151 | <body> 1152 1152 -
trunk/Source/WebCore/ChangeLog
r147178 r147185 1 2013-03-28 Rafael Weinstein <rafaelw@chromium.org> 2 3 [HTMLTemplateElement] <template> should be able to be a foster parent 4 https://bugs.webkit.org/show_bug.cgi?id=113541 5 6 Reviewed by Eric Seidel 7 8 This adds to the check in findFosterSite to include whether the parent is a DocumentFragment which is a template contents. 9 10 Tests added to html5lib suite. 11 12 * html/parser/HTMLConstructionSite.cpp: 13 (WebCore::HTMLConstructionSite::findFosterSite): 14 1 15 2013-03-28 Xianzhu Wang <wangxianzhu@chromium.org> 2 16 -
trunk/Source/WebCore/html/parser/HTMLConstructionSite.cpp
r147057 r147185 630 630 // When parsing HTML fragments, we skip step 4.2 ("Let root be a new html element with no attributes") for efficiency, 631 631 // and instead use the DocumentFragment as a root node. So we must treat the root node (DocumentFragment) as if it is a html element here. 632 if (parent && (parent->isElementNode() || (m_isParsingFragment && parent == m_openElements.rootNode()))) { 632 bool parentCanBeFosterParent = parent && (parent->isElementNode() || (m_isParsingFragment && parent == m_openElements.rootNode())); 633 #if ENABLE(TEMPLATE_ELEMENT) 634 parentCanBeFosterParent = parentCanBeFosterParent || (parent && parent->isDocumentFragment() && static_cast<DocumentFragment*>(parent)->isTemplateContent()); 635 #endif 636 if (parentCanBeFosterParent) { 633 637 task.parent = parent; 634 638 task.nextChild = lastTableElement;
Note: See TracChangeset
for help on using the changeset viewer.