Changeset 63037 in webkit
- Timestamp:
- Jul 9, 2010 8:47:55 PM (14 years ago)
- Location:
- trunk/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebCore/ChangeLog
r63036 r63037 1 2010-07-09 Adam Barth <abarth@webkit.org> 2 3 Reviewed by Eric Seidel. 4 5 HTML5 tree builder should pass some LayoutTests 6 https://bugs.webkit.org/show_bug.cgi?id=41991 7 8 Before this patch, we weren't attaching text nodes to the render tree, 9 which turns out to be important. :) 10 11 This patch fixes more than 10,000 LayoutTests. 12 13 * html/HTMLConstructionSite.cpp: 14 (WebCore::HTMLConstructionSite::attach): 15 (WebCore::HTMLConstructionSite::attachAtSite): 16 1 17 2010-07-09 Patrick Gansterer <paroga@paroga.com> 2 18 -
trunk/WebCore/html/HTMLConstructionSite.cpp
r62926 r63037 83 83 if (m_redirectAttachToFosterParent) { 84 84 fosterParent(child.get()); 85 ASSERT(child->attached()); 85 86 return child.release(); 86 87 } … … 92 93 // for elements), however, we'll get to use this ref in the stack of 93 94 // open elements. 95 ASSERT(parent->attached()); 96 ASSERT(!child->attached()); 94 97 child->attach(); 95 98 return child.release(); 96 99 } 97 100 98 void HTMLConstructionSite::attachAtSite(const AttachmentSite& site, PassRefPtr<Node> child) 99 { 101 void HTMLConstructionSite::attachAtSite(const AttachmentSite& site, PassRefPtr<Node> prpChild) 102 { 103 RefPtr<Node> child = prpChild; 104 100 105 if (site.nextChild) { 101 106 // FIXME: We need an insertElement which does not send mutation events. 102 107 ExceptionCode ec = 0; 103 108 site.parent->insertBefore(child, site.nextChild, ec); 104 // FIXME: Do we need to call attach()?105 109 ASSERT(!ec); 110 ASSERT(site.parent->attached()); 111 if (!child->attached()) 112 child->attach(); 106 113 return; 107 114 } 108 115 site.parent->parserAddChild(child); 109 // FIXME: Do we need to call attach()? 116 // It's slightly unfortunate that we need to hold a reference to child 117 // here to call attach(). We should investigate whether we can rely on 118 // |site.parent| to hold a ref at this point. 119 ASSERT(site.parent->attached()); 120 if (!child->attached()) 121 child->attach(); 110 122 } 111 123
Note: See TracChangeset
for help on using the changeset viewer.