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

Commit 64a66804 authored by Shailen Tuli's avatar Shailen Tuli
Browse files

Added INDETERMINATE static field to RangeInfo

Test: CTS test added

Bug: 378936330

Flag: android.view.accessibility.indeterminate_range_info

Change-Id: I07e843d8908c806e1b21fdfa79dd73e0fba47850
parent 377ad55b
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -56486,6 +56486,7 @@ package android.view.accessibility {
    method public float getMin();
    method public int getType();
    method @Deprecated public static android.view.accessibility.AccessibilityNodeInfo.RangeInfo obtain(int, float, float, float);
    field @FlaggedApi("android.view.accessibility.indeterminate_range_info") @NonNull public static final android.view.accessibility.AccessibilityNodeInfo.RangeInfo INDETERMINATE;
    field public static final int RANGE_TYPE_FLOAT = 1; // 0x1
    field @FlaggedApi("android.view.accessibility.indeterminate_range_info") public static final int RANGE_TYPE_INDETERMINATE = 3; // 0x3
    field public static final int RANGE_TYPE_INT = 0; // 0x0
+12 −4
Original line number Diff line number Diff line
@@ -6551,15 +6551,23 @@ public class AccessibilityNodeInfo implements Parcelable {
        /**
         * Range type: indeterminate.
         *
         * When using this type, the {@code min}, {@code max}, and {@code current} values used to
         * construct an instance may be ignored.
         *
         *  @see #INDETERMINATE
         */
        @FlaggedApi(Flags.FLAG_INDETERMINATE_RANGE_INFO)
        public static final int RANGE_TYPE_INDETERMINATE = 3;

        /**
         * A {@link RangeInfo} type used to represent a node which may typically expose range
         * information but is presently in an indeterminate state, such as a {@link
         * android.widget.ProgressBar} representing a loading operation of unknown duration.
         * When using this type, the {@code min}, {@code max}, and {@code current} values used to
         * construct an instance may be ignored. It is recommended to use {@code Float.NaN} for
         * these values.
         */
        @NonNull
        @FlaggedApi(Flags.FLAG_INDETERMINATE_RANGE_INFO)
        public static final int RANGE_TYPE_INDETERMINATE = 3;
        public static final RangeInfo INDETERMINATE = new RangeInfo(RANGE_TYPE_INDETERMINATE, 0.0f,
                0.0f, 0.0f);

        private int mType;
        private float mMin;