diff options
| author | Gilles Debunne <debunne@google.com> | 2011-02-25 15:18:03 -0800 |
|---|---|---|
| committer | Gilles Debunne <debunne@google.com> | 2011-02-25 15:18:03 -0800 |
| commit | 4b2274fff53356d32e07585a566d2c73c92272a3 (patch) | |
| tree | 84700f24589cc822b671941280d737c52b5eb6f7 /core/java/android | |
| parent | 7ad9eb69c45fae0712f767a4b70f670113da92d9 (diff) | |
Text selection mode is stopped when View is recycled in ListView
Change-Id: If09cef9485ccc35c53ad9c7a809c982e32da2f0e
Diffstat (limited to 'core/java/android')
| -rw-r--r-- | core/java/android/widget/TextView.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/core/java/android/widget/TextView.java b/core/java/android/widget/TextView.java index ce88c775c14f..00445de5e4b9 100644 --- a/core/java/android/widget/TextView.java +++ b/core/java/android/widget/TextView.java @@ -7091,6 +7091,11 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener // Only track when onStartTemporaryDetach() is called directly, // usually because this instance is an editable field in a list if (!mDispatchTemporaryDetach) mTemporaryDetach = true; + + // Because of View recycling in ListView, there is no easy way to know when a TextView with + // selection becomes visible again. Until a better solution is found, stop text selection + // mode (if any) as soon as this TextView is recycled. + stopSelectionActionMode(); } @Override |
