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

Commit 4ce651e9 authored by Abodunrinwa Toki's avatar Abodunrinwa Toki
Browse files

TextView: Invalidate selection action mode on "select all".

Test: bit FrameworksCoreTests:android.widget.TextViewActivityTest
bit CtsWidgetTestCases:android.widget.cts.TextViewTest
Change-Id: I0b5ebb8d6f1af1a9938151f758a2feedb14fcb9f
Fixes: 38244876
parent 6bf9b9a5
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2016,7 +2016,7 @@ public class Editor {
    /**
     * Asynchronously invalidates an action mode using the TextClassifier.
     */
    private void invalidateActionModeAsync() {
    void invalidateActionModeAsync() {
        getSelectionActionModeHelper().invalidateActionModeAsync();
    }

+4 −0
Original line number Diff line number Diff line
@@ -10756,7 +10756,11 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener

        switch (id) {
            case ID_SELECT_ALL:
                final boolean hadSelection = hasSelection();
                selectAllText();
                if (mEditor != null && hadSelection) {
                    mEditor.invalidateActionModeAsync();
                }
                return true;

            case ID_UNDO: