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

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

Issue 23450030: Introduce Position::inDocument() (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 3 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/editing/ApplyBlockElementCommand.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/Position.h
diff --git a/Source/core/dom/Position.h b/Source/core/dom/Position.h
index d423a28660ad850ef4276a5131c3a70a6ef3f3da..d2b1d1e552fa20b0ee464fa32e2dde7ba10a95a4 100644
--- a/Source/core/dom/Position.h
+++ b/Source/core/dom/Position.h
@@ -128,6 +128,7 @@ public:
Node* deprecatedNode() const { return m_anchorNode.get(); }
Document* document() const { return m_anchorNode ? &m_anchorNode->document() : 0; }
+ bool inDocument() const { return m_anchorNode && m_anchorNode->inDocument(); }
Element* rootEditableElement() const
{
Node* container = containerNode();
« no previous file with comments | « no previous file | Source/core/editing/ApplyBlockElementCommand.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698