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

Unified Diff: third_party/WebKit/Source/core/html/TextControlElement.cpp

Issue 2969183002: Use FrameSelection::Granularity in TextControlElement::ComputeSelection{Start,End}() (Closed)
Patch Set: 2017-07-05T15:47:49 Created 3 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/html/TextControlElement.cpp
diff --git a/third_party/WebKit/Source/core/html/TextControlElement.cpp b/third_party/WebKit/Source/core/html/TextControlElement.cpp
index 5dd854b4cfdf2e2869217331d46baa95a09ccb67..12bb8af943923a7039a1b4be52f10f9f0aafaa82 100644
--- a/third_party/WebKit/Source/core/html/TextControlElement.cpp
+++ b/third_party/WebKit/Source/core/html/TextControlElement.cpp
@@ -503,7 +503,7 @@ unsigned TextControlElement::ComputeSelectionStart() const {
GetDocument().Lifecycle());
const SelectionInDOMTree& selection =
frame->Selection().GetSelectionInDOMTree();
- if (selection.Granularity() == kCharacterGranularity) {
+ if (frame->Selection().Granularity() == kCharacterGranularity) {
return IndexForPosition(InnerEditorElement(),
selection.ComputeStartPosition());
}
@@ -534,7 +534,7 @@ unsigned TextControlElement::ComputeSelectionEnd() const {
GetDocument().Lifecycle());
const SelectionInDOMTree& selection =
frame->Selection().GetSelectionInDOMTree();
- if (selection.Granularity() == kCharacterGranularity) {
+ if (frame->Selection().Granularity() == kCharacterGranularity) {
return IndexForPosition(InnerEditorElement(),
selection.ComputeEndPosition());
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698