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

Unified Diff: Source/core/dom/ContainerNode.h

Issue 425383002: Move highestAncestorOrSelf() from Node to NodeTraversal (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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 | « no previous file | Source/core/dom/Node.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/ContainerNode.h
diff --git a/Source/core/dom/ContainerNode.h b/Source/core/dom/ContainerNode.h
index 198a191ae905a19a2e8f643e621e48fbe2b38342..e65fc4376a223d0bee5f2e7618a92ac04a30e0ad 100644
--- a/Source/core/dom/ContainerNode.h
+++ b/Source/core/dom/ContainerNode.h
@@ -295,15 +295,6 @@ inline Node* Node::lastChild() const
return toContainerNode(this)->lastChild();
}
-inline Node& Node::highestAncestorOrSelf() const
-{
- Node* node = const_cast<Node*>(this);
- Node* highest = node;
- for (; node; node = node->parentNode())
- highest = node;
- return *highest;
-}
-
inline ContainerNode* Node::parentElementOrShadowRoot() const
{
ContainerNode* parent = parentNode();
« no previous file with comments | « no previous file | Source/core/dom/Node.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698