summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/java/android/widget/Editor.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/java/android/widget/Editor.java b/core/java/android/widget/Editor.java
index ff0950a3da72..c96d39b0f384 100644
--- a/core/java/android/widget/Editor.java
+++ b/core/java/android/widget/Editor.java
@@ -4173,7 +4173,7 @@ public class Editor {
if (!mInWord || currLine < mPrevLine) {
// We're not in a word, or we're on a different line so we'll expand by
// word. First ensure the user has at least entered the next word.
- int offsetToWord = Math.min((end - start) / 2, 2);
+ int offsetToWord = (end - start) / 2;
if (offset <= end - offsetToWord || currLine < mPrevLine) {
offset = start;
} else {
@@ -4354,7 +4354,7 @@ public class Editor {
if (!mInWord || currLine > mPrevLine) {
// We're not in a word, or we're on a different line so we'll expand by
// word. First ensure the user has at least entered the next word.
- int midPoint = Math.min((end - start) / 2, 2);
+ int midPoint = (end - start) / 2;
if (offset >= start + midPoint || currLine > mPrevLine) {
offset = end;
} else {