summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorAbodunrinwa Toki <toki@google.com>2015-10-20 17:47:28 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2015-10-20 17:47:28 +0000
commit3bd3655fd05a548f6e60cfccd4185a4b9ae2a7d6 (patch)
tree4de9120bc969490e69084914b9f6f4f5a0b91e50 /core
parent1a4efb77dd3c503634f1f6495d931d1a570f51f5 (diff)
parent3b8a5ea036670421ef962d6ed8b22d214e933711 (diff)
downloadframeworks_base-3bd3655fd05a548f6e60cfccd4185a4b9ae2a7d6.zip
frameworks_base-3bd3655fd05a548f6e60cfccd4185a4b9ae2a7d6.tar.gz
frameworks_base-3bd3655fd05a548f6e60cfccd4185a4b9ae2a7d6.tar.bz2
Merge "Re-set PROCESS_TEXT selection if nothing was returned." into mnc-dr-dev
Diffstat (limited to 'core')
-rw-r--r--core/java/android/widget/TextView.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/core/java/android/widget/TextView.java b/core/java/android/widget/TextView.java
index a1462c4..d8139b8 100644
--- a/core/java/android/widget/TextView.java
+++ b/core/java/android/widget/TextView.java
@@ -1474,7 +1474,12 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
}
}
}
+ } else if (mText instanceof Spannable) {
+ // Reset the selection.
+ stopTextActionMode();
+ Selection.setSelection((Spannable) mText, getSelectionStart(), getSelectionEnd());
}
+
if (mEditor.hasSelectionController()) {
mEditor.startSelectionActionMode();
}