Index: third_party/WebKit/Source/core/editing/commands/InsertIncrementalTextCommand.cpp |
diff --git a/third_party/WebKit/Source/core/editing/commands/InsertIncrementalTextCommand.cpp b/third_party/WebKit/Source/core/editing/commands/InsertIncrementalTextCommand.cpp |
index d0dd77ed19d88503e4b70e480b6f60f395ea602d..375c0fe59b10cb091d3e21552d5c19cfde4e4f60 100644 |
--- a/third_party/WebKit/Source/core/editing/commands/InsertIncrementalTextCommand.cpp |
+++ b/third_party/WebKit/Source/core/editing/commands/InsertIncrementalTextCommand.cpp |
@@ -45,19 +45,6 @@ size_t computeCommonSuffixLength(const String& str1, const String& str2) { |
return maxCommonSuffixLength; |
} |
-// If current position is at grapheme boundary, return 0; otherwise, return the |
-// distance to its nearest left grapheme boundary. |
-size_t computeDistanceToLeftGraphemeBoundary(const Position& position) { |
- const Position& adjustedPosition = previousPositionOf( |
- nextPositionOf(position, PositionMoveType::GraphemeCluster), |
- PositionMoveType::GraphemeCluster); |
- DCHECK_EQ(position.anchorNode(), adjustedPosition.anchorNode()); |
- DCHECK_GE(position.computeOffsetInContainerNode(), |
- adjustedPosition.computeOffsetInContainerNode()); |
- return static_cast<size_t>(position.computeOffsetInContainerNode() - |
- adjustedPosition.computeOffsetInContainerNode()); |
-} |
- |
size_t computeCommonGraphemeClusterPrefixLength(const Position& selectionStart, |
const String& oldText, |
const String& newText) { |
@@ -78,19 +65,6 @@ size_t computeCommonGraphemeClusterPrefixLength(const Position& selectionStart, |
return commonPrefixLength - diff; |
} |
-// If current position is at grapheme boundary, return 0; otherwise, return the |
-// distance to its nearest right grapheme boundary. |
-size_t computeDistanceToRightGraphemeBoundary(const Position& position) { |
- const Position& adjustedPosition = nextPositionOf( |
- previousPositionOf(position, PositionMoveType::GraphemeCluster), |
- PositionMoveType::GraphemeCluster); |
- DCHECK_EQ(position.anchorNode(), adjustedPosition.anchorNode()); |
- DCHECK_GE(adjustedPosition.computeOffsetInContainerNode(), |
- position.computeOffsetInContainerNode()); |
- return static_cast<size_t>(adjustedPosition.computeOffsetInContainerNode() - |
- position.computeOffsetInContainerNode()); |
-} |
- |
size_t computeCommonGraphemeClusterSuffixLength(const Position& selectionStart, |
const String& oldText, |
const String& newText) { |