Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4b2274ff authored by Gilles Debunne's avatar Gilles Debunne
Browse files

Text selection mode is stopped when View is recycled in ListView

Change-Id: If09cef9485ccc35c53ad9c7a809c982e32da2f0e
parent 7ad9eb69
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -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