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

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

Issue 1987983002: Remove Range.expand() method Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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/Range.h ('k') | third_party/WebKit/Source/core/dom/Range.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/Range.cpp
diff --git a/third_party/WebKit/Source/core/dom/Range.cpp b/third_party/WebKit/Source/core/dom/Range.cpp
index 4ccba20c1e763c9a6378159a32be036b4eb01fe7..d39c242afa2497270b376e9836aa0f80c099cc2a 100644
--- a/third_party/WebKit/Source/core/dom/Range.cpp
+++ b/third_party/WebKit/Source/core/dom/Range.cpp
@@ -1498,29 +1498,6 @@ void Range::didSplitTextNode(Text& oldNode)
DCHECK(boundaryPointsValid());
}
-void Range::expand(const String& unit, ExceptionState& exceptionState)
-{
- VisiblePosition start = createVisiblePosition(startPosition());
- VisiblePosition end = createVisiblePosition(endPosition());
- if (unit == "word") {
- start = startOfWord(start);
- end = endOfWord(end);
- } else if (unit == "sentence") {
- start = startOfSentence(start);
- end = endOfSentence(end);
- } else if (unit == "block") {
- start = startOfParagraph(start);
- end = endOfParagraph(end);
- } else if (unit == "document") {
- start = startOfDocument(start);
- end = endOfDocument(end);
- } else {
- return;
- }
- setStart(start.deepEquivalent().computeContainerNode(), start.deepEquivalent().computeOffsetInContainerNode(), exceptionState);
- setEnd(end.deepEquivalent().computeContainerNode(), end.deepEquivalent().computeOffsetInContainerNode(), exceptionState);
-}
-
ClientRectList* Range::getClientRects() const
{
m_ownerDocument->updateLayoutIgnorePendingStylesheets();
« no previous file with comments | « third_party/WebKit/Source/core/dom/Range.h ('k') | third_party/WebKit/Source/core/dom/Range.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698