Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(133)

Unified Diff: third_party/WebKit/Source/core/dom/Node.cpp

Issue 1855823003: Implement Node.isConnected (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/core/dom/Node.h ('k') | third_party/WebKit/Source/core/dom/Node.idl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/dom/Node.cpp
diff --git a/third_party/WebKit/Source/core/dom/Node.cpp b/third_party/WebKit/Source/core/dom/Node.cpp
index da9b660fe040cfcefff918acd9093e59c4e0e16d..9a040e14fcf6e91b80c0cdcb6aaf51de0e161dcd 100644
--- a/third_party/WebKit/Source/core/dom/Node.cpp
+++ b/third_party/WebKit/Source/core/dom/Node.cpp
@@ -783,6 +783,11 @@ unsigned Node::nodeIndex() const
return count;
}
+bool Node::isConnected() const
hayato 2016/04/04 05:32:52 I think we can use Node::inDocument() for Node.isC
yuzuchan 2016/04/04 07:09:30 Acknowledged. I will start another CL to rename in
+{
+ return isInShadowTree() ? shadowHost()->treeRoot().isSameNode(ownerDocument()) : treeRoot().isSameNode(ownerDocument());
+}
+
NodeListsNodeData* Node::nodeLists()
{
return hasRareData() ? rareData()->nodeLists() : nullptr;
« no previous file with comments | « third_party/WebKit/Source/core/dom/Node.h ('k') | third_party/WebKit/Source/core/dom/Node.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698