[Webkit-unassigned] [Bug 119325] New: compareDocumentPosition() reports an attribute and its content as disconnected
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Jul 30 23:37:24 PDT 2013
https://bugs.webkit.org/show_bug.cgi?id=119325
Summary: compareDocumentPosition() reports an attribute and its
content as disconnected
Product: WebKit
Version: 528+ (Nightly build)
Platform: Unspecified
OS/Version: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: HTML DOM
AssignedTo: webkit-unassigned at lists.webkit.org
ReportedBy: dchris at gmail.com
CC: darin at apple.com, ap at webkit.org, rniwa at webkit.org
Node::compareDocumentPosition() reports an attribute and its content as disconnected.
Instead, the attribute should contain and precede its content.
This is causing the following test case to fail:
LayoutTests/dom/xhtml/level3/core/nodecomparedocumentposition38.xhtml
I investigated the issue a bit and it seems the problem seems to be that Node::inDocument() returns false for the Text node (content) instead of true.
Note that there is already a workaround in place in Node::compareDocumentPositionInternal() that addresses the same issue for Attribute nodes.
See comment in that method:
// Note that we avoid comparing Attr nodes here, since they return false from inDocument() all the time (which seems like a bug).
It is likely we need to extend the workaround to Text nodes or fix the underlying problem (have inDocument() return correct values for Attr and Text nodes).
Specification:
http://dom.spec.whatwg.org/#dom-node-comparedocumentposition
Corresponding Blink bug:
http://code.google.com/p/chromium/issues/detail?id=264138
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list