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

Commit a3d17a75 authored by Svetoslav Ganov's avatar Svetoslav Ganov Committed by Android (Google) Code Review
Browse files

Merge "Text in accessibility events not consistent"

parents d1daaa21 c0a8cd10
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -159,7 +159,12 @@ public final class AccessibilityEvent implements Parcelable {
     *
     * @see #getBeforeText()
     * @see #getText()
     * </br>
     * Note: This constant is no longer needed since there
     *       is no limit on the length of text that is contained
     *       in an accessibility event anymore.
     */
    @Deprecated
    public static final int MAX_TEXT_LENGTH = 500;

    /**
+0 −3
Original line number Diff line number Diff line
@@ -7898,9 +7898,6 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
                text = getHint();
            }
            if (!TextUtils.isEmpty(text)) {
                if (text.length() > AccessibilityEvent.MAX_TEXT_LENGTH) {
                    text = text.subSequence(0, AccessibilityEvent.MAX_TEXT_LENGTH + 1);
                }
                event.getText().add(text);
            }
        } else {