Changeset 243734 in webkit
- Timestamp:
- Apr 1, 2019, 8:14:50 PM (7 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
-
LayoutTests/imported/w3c/ChangeLog (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/dom/nodes/Document-importNode-expected.txt (modified) (1 diff)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/dom/Document.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/imported/w3c/ChangeLog
r243705 r243734 1 2019-04-01 Chris Dumez <cdumez@apple.com> 2 3 Attr nodes are not cloned properly 4 https://bugs.webkit.org/show_bug.cgi?id=196466 5 6 Reviewed by Ryosuke Niwa. 7 8 Rebaseline WPT test now that one more check is passing. 9 10 * web-platform-tests/dom/nodes/Document-importNode-expected.txt: 11 1 12 2019-04-01 Chris Dumez <cdumez@apple.com> 2 13 -
trunk/LayoutTests/imported/w3c/web-platform-tests/dom/nodes/Document-importNode-expected.txt
r229544 r243734 4 4 PASS True 'deep' argument. 5 5 PASS False 'deep' argument. 6 FAIL Import an Attr node with namespace/prefix correctly. assert_equals: expected (string) "p" but got (object) null 6 PASS Import an Attr node with namespace/prefix correctly. 7 7 -
trunk/Source/WebCore/ChangeLog
r243730 r243734 1 2019-04-01 Chris Dumez <cdumez@apple.com> 2 3 Attr nodes are not cloned properly 4 https://bugs.webkit.org/show_bug.cgi?id=196466 5 6 Reviewed by Ryosuke Niwa. 7 8 Attr nodes are not cloned properly according to: 9 - https://dom.spec.whatwg.org/#concept-node-clone 10 11 A cloned Attr node should retain its prefix and namespace. 12 13 Both Gecko and Blink agree with the DOM specification here. 14 15 No new tests, rebaselined existing test. 16 17 * dom/Document.cpp: 18 (WebCore::Document::importNode): 19 1 20 2019-04-01 Said Abou-Hallawa <sabouhallawa@apple.com> 2 21 -
trunk/Source/WebCore/dom/Document.cpp
r243686 r243734 989 989 return nodeToImport.cloneNodeInternal(document(), deep ? CloningOperation::Everything : CloningOperation::OnlySelf); 990 990 991 case ATTRIBUTE_NODE: 992 // FIXME: This will "Attr::normalize" child nodes of Attr.993 return Ref<Node> { Attr::create(*this, QualifiedName(nullAtom(), downcast<Attr>(nodeToImport).name(), nullAtom()), downcast<Attr>(nodeToImport).value()) };994 991 case ATTRIBUTE_NODE: { 992 auto& attribute = downcast<Attr>(nodeToImport); 993 return Ref<Node> { Attr::create(*this, attribute.qualifiedName(), attribute.value()) }; 994 } 995 995 case DOCUMENT_NODE: // Can't import a document into another document. 996 996 case DOCUMENT_TYPE_NODE: // FIXME: Support cloning a DocumentType node per DOM4.
Note:
See TracChangeset
for help on using the changeset viewer.