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

Unified Diff: Source/core/editing/ReplaceSelectionCommand.h

Issue 420323002: Move Node::lastDescendantOrSelf() to NodeTraversal and rename to lastWithinOrSelf() (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase 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 | « Source/core/editing/DeleteSelectionCommand.cpp ('k') | Source/core/editing/ReplaceSelectionCommand.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/editing/ReplaceSelectionCommand.h
diff --git a/Source/core/editing/ReplaceSelectionCommand.h b/Source/core/editing/ReplaceSelectionCommand.h
index fdd632ff895ef9785247cc217f29c13152e42b5f..e08f1ed770032287ea12508d5d653a328597da1a 100644
--- a/Source/core/editing/ReplaceSelectionCommand.h
+++ b/Source/core/editing/ReplaceSelectionCommand.h
@@ -69,8 +69,8 @@ private:
void didReplaceNode(Node&, Node& newNode);
Node* firstNodeInserted() const { return m_firstNodeInserted.get(); }
- Node* lastLeafInserted() const { return m_lastNodeInserted ? &m_lastNodeInserted->lastDescendantOrSelf() : 0; }
- Node* pastLastLeaf() const { return m_lastNodeInserted ? NodeTraversal::next(m_lastNodeInserted->lastDescendantOrSelf()) : 0; }
+ Node* lastLeafInserted() const { return m_lastNodeInserted ? &NodeTraversal::lastWithinOrSelf(*m_lastNodeInserted) : 0; }
+ Node* pastLastLeaf() const { return m_lastNodeInserted ? NodeTraversal::next(NodeTraversal::lastWithinOrSelf(*m_lastNodeInserted)) : 0; }
private:
RefPtrWillBeMember<Node> m_firstNodeInserted;
« no previous file with comments | « Source/core/editing/DeleteSelectionCommand.cpp ('k') | Source/core/editing/ReplaceSelectionCommand.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698