summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGilles Debunne <debunne@google.com>2011-12-13 14:47:19 -0800
committerGilles Debunne <debunne@google.com>2011-12-13 14:47:26 -0800
commit770f0fa92e0745c523be466e3520d22f51e28bb1 (patch)
tree7adce5dc42688f96698c525421fbfe50d25f904d
parentf0bbc494d638f4c77e688bf9410027f453301559 (diff)
downloadbase-770f0fa92e0745c523be466e3520d22f51e28bb1.tar.gz
Do not spell check the foreground ExtractEditText.
Bug 5755099 In extracted text mode, we spell check the background and the foreground edit text. All changes in the background are already propagated to the foreground, and updates on the foreground may trigger a spell check of the entire text since we use setText. Change-Id: Ie44c3d9113258082ac6df5890851d0e21c702ea2
-rw-r--r--core/java/android/widget/TextView.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/java/android/widget/TextView.java b/core/java/android/widget/TextView.java
index 67facbcb6997..b9d3d43e0a7c 100644
--- a/core/java/android/widget/TextView.java
+++ b/core/java/android/widget/TextView.java
@@ -7802,7 +7802,7 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
* Create new SpellCheckSpans on the modified region.
*/
private void updateSpellCheckSpans(int start, int end, boolean createSpellChecker) {
- if (isTextEditable() && isSuggestionsEnabled()) {
+ if (isTextEditable() && isSuggestionsEnabled() && !(this instanceof ExtractEditText)) {
if (mSpellChecker == null && createSpellChecker) {
mSpellChecker = new SpellChecker(this);
}