Bug: 213940323
Test: ran atest android.widget.cts.ExpandableListViewTest and manually verified through talkback tests.
Change-Id: I8e9523781edd0dfd76c422da219beccf1a39a298
Revert submission 19246592-accessibility-tool-only
Reason for revert: Jank regression b/242267091
Reverted Changes:
I0685e6dd4:CTS tests for the accessibilityDataPrivate propert...
I1c02af88c:Limit off-label accessibility access using a new p...
Change-Id: I701b811fd4fb2634872a759134356736a7e8b7dd
Specified the accessibilityService CTS tests to run for core presubmit.
Test: Should fix broken tests in AccessibilityTextActionTest
Bug: 241784682
Change-Id: I9b5fd1b2850b26815dea73080ad21aeb3d177bfe
Test: atest CtsContentCaptureServiceTestCases, observed events reported only once on scroll and stop as well as on fling
Bug: 211899037
Change-Id: Id67fcc360bf63fcab1d9f345c31d2bf7b9a173d6
> This would allow us to easily extect the options
> Also passing the executor for async inflation. This will allow
containing adapters to also be async if the parent View is using
async inflation
Bug: 202766048
Test: Presubmit
Change-Id: I60a9b5db5f9b5f8d6e56521ee00de4be30decce6
In horizontal layouts, when elements are rendered from LTR, the
definition of "before" and "after" gets flipped, causing the divider
spacing to be allocated to the wrong locations. By flipping the check in
RTL layouts, the dividers can be placed correctly.
Additionally, it is necessary to add divider measurements to all layout
width measurements to allow for dividers in right gravity to layout
properly.
Bug: 208927871
Test: atest android.widget.cts.LinearLayoutTest
Change-Id: If6e917873571484a6fb1dfc28b356289e2cc1ffa
Floating toolbar, magnifier and tear drop selection handles are
designed for finger touch input. For the mouse UX, these UI will
not be good. So hiding them if the TextView/EditText has interacted
with mouse device.
Bug: 240383641
Test: atest TextViewMouseInteractionTest
Change-Id: I66f169ee3f2b77e3a066aecb07170e82248c2cde
Cursor continues to blink in a text field even when the text field is
not currently visible. This change checks the visibility of the window
that houses the text field in addition to checking if the view is in
focus.
Bug: 228354442
Test: Added logging to the shouldBlink() method ran following steps:
1: open contacts app
2: tap add new contact, tap in an edit field
3: move back to home screen
4: lock screen, then unlock screen
5: observed logs written out to logcat console when app not
visible.
after change logs no longer printed to console, cursor still blinks
correctly after app is re-opened or when new field becomes in
focus.
Test: CtsWidgetTestCases:EditTextTest#
testCursorNotBlinkingOnNewActivity_WithoutFocus()
testCursorBlinkingOnNewActivity_WithFocus()
testSuspendAndResumeBlinkingCursor()
Change-Id: Iad4396e5f7fd810344c711320d65c57ea25eda70
TextView.setText(char[]) is from API 1 and follows a running with
scissors API style of not copying the passed array.
To avoid a leak, in TextView.setText(String), the char[] would be nulled
out. However, an internal object could have been read using .getText()
prior to this second setText would immmediatly become a
CharSequence that crashed when you called any methods on it.
After this change, the CharWrapper will stay valid if had been
previously retrieved. The general shape of the API will be maintained.
Fixes: b/227218386
Test: atest android.widget.TextViewTest
Relnote: "Calling TextView.getText() after calling TextView.setText(char[])
will now return a valid CharSequence. The char[] pointed to by this char
sequnece may still be mutated by future calls to setText(char[]), but it
will no longer allow a (char[]) null to be set, which lead to crashes
when reading CharSequence returned from getText on TextView."
Merged-In: I35a2a76d58ec1946dace2f615cacf6a6085efdeb
Change-Id: I35a2a76d58ec1946dace2f615cacf6a6085efdeb
(cherry picked from commit 166c7217f4)
Add @NonNull to TextView.setText(@NonNull char[], ...)
This has always thrown a NPE since API 1.
Bug: b/227218386
Test: atest android.widget.TextViewTest
Relnote: "TextView.setText(@NonNull char[], ...) added nullability
annotation."
Change-Id: I212bb5b73d00185f83adb5e74d4acd07a1410ca8
TextView.setText(char[]) is from API 1 and follows a running with
scissors API style of not copying the passed array.
To avoid a leak, in TextView.setText(String), the char[] would be nulled
out. However, an internal object could have been read using .getText()
prior to this second setText would immmediatly become a
CharSequence that crashed when you called any methods on it.
After this change, the CharWrapper will stay valid if had been
previously retrieved. The general shape of the API will be maintained.
Fixes: b/227218386
Test: atest android.widget.TextViewTest
Relnote: "Calling TextView.getText() after calling TextView.setText(char[])
will now return a valid CharSequence. The char[] pointed to by this char
sequnece may still be mutated by future calls to setText(char[]), but it
will no longer allow a (char[]) null to be set, which lead to crashes
when reading CharSequence returned from getText on TextView."
Change-Id: I35a2a76d58ec1946dace2f615cacf6a6085efdeb
Bug: 232903223
When a user flings the overscroll toward the scrolling
content, the user might think that any left-over velocity
should apply to scrolling the content. This CL makes that
happen. If the fling is less than the overscroll distance,
then the normal spring is applied.
This CL changes ListView, ScrollView, and HorizontalScrollView.
Test: manual testing and new CTS tests
Change-Id: I1a759377f5183eec805598a6b016515297191624