TouchExplorer supports multi-finger gestures from R. However,
FullScreenMagnificationGestureHandler has higher priority of
receiving motion events than TouchExplorer. When the screen is
zoomed in, two pointersdown gesture makes it transiting to
PanningScalingState.
To fix it, We post a tap tmeout to transit to PanningScalingState
when receiving two pointers down. In this duration, any pointers
action will make it transiting to DelegatingState. We also add
a condition that is if the movement of any fingers exceeed the
touchSlope, it will transit to PanningScalingState.
Bug: 159508732
Test: atest FullScreenMagnificationGestureHandlerTest
atest MagnificationGestureHandlerTest
Change-Id: Ic72c0da68a6a4f1714da8d05f743d6218793a5da
The double-tap/touch slope is from system's double-tap detector.
This threshold is too narrow for multi-finger multi-tap. It ends up
canceling the detection when the movement exceed the slope.
We adjust the slopes by multiplying the target finger count.
The maxium slope in 4 fingers is around 4.48 mm is smaller than
the swipe threshold (1 cm)
Bug: 158725482
Test: atest GestureManifoldTest
atest TouchExplorerTest
atest AccessibilityGestureDetectorTest
Change-Id: If0927d15d61a9682da67721d0bf0bbbc1045078b
Require that the PendingIntent be immutable so that a malicious app is
not able to hijack and mutate any of the details.
Bug: 154913130
Test: a11y CTS & unit tests
Change-Id: Ib794fa9e80b2a6c5562c66a0c17ea7c92c500e19
(cherry picked from commit a0b630075a)
TYPE_TRUSTED_APPLICATION_OVERLAY is a system window type used in
Bubble. We map it to system window type for AccesibiltiyWindowInfo
Bug: 158066152
Test: Enable bubble window and observe its type of
AccessibilityWindowInfo
Change-Id: I597d360a79fc61dbf4a3d713004272d33d40e576
ACCESSIBILITY_DISPLAY_MAGNIFICATION_NAVBAR_ENABLED is replaced
with ButtonTargets setting value. We address it in data migration but
not in D2D
Consider D2D, we restore it to ButtonTargets value when the restored
sdk version of the received intent is below R.
Bug: 155943759
Test: manual test
1. prepare an Android Q device and an Android R device
2. backup settings value of Android Q device by the google account.
3. Launch setupwizard to restore it by the google account.
Change-Id: I5df070dd1ef880ac1ee5c0867b42e88782348a1b
From Android R, we add ButtonTargets settings value for the shortcut feature.
It has dependency with enabled services requesting the Accessibility
button. In D2D case, we don't update it.
We mirgate the ButtonTargets value if enabled services are changed by D2D.
Bug: 156459064
Test: manual test:
1. prepare an Android Q device and an Android R device
2. backup settings value of Android Q device by google account.
3. Launch setupwizard to restore it by google account.
Change-Id: I8924171162be84f9a24ca3ea124234118b1183f5
We were resetting the expiration clock every time a finger went down, but were not resetting it when fingers went up. As a result the user had a super narrow window to get all the fingers up before the gesture canceled.
Bug: 156880174
Test: atest GestureManifoldTest
Change-Id: I81dd9cd67729cfae38952d44295c3340c5426028
Change-Id: I1b6323ac413bcbd46fd9292fbb4cf7ebdf2b6246
The virtual display of the activity became private and A11y framework
won't track the windows of the private virtual display. Then the change
of bubbles using the activityView could not be notified to A11y
framework.
Due to the bubbles created from system ui, we made the private virtual
display created from system ui could track its windows.
This is the short term solution, and only phases in rvc-dev branch. We
plan to track all private virtual displays as the long term solution at
master branch, but need to avoid this issue happened again, b/148760652.
Bug: 156685691
Test: a11y CTS & unit tests
Change-Id: I7a7e3d6040ce05f5d3769c14d34f906d8042c473
The accessibility button and shortcut target is updated by
the Settings app when the user turn on/off the a11y service.
It worked fine before an a11y service disables and turns off
itself using disableSelf api. The accessibility button and
shortcut settings can not get update in this case. Removes
shortcut target if an a11y service is unbound to fix this
issue.
Bug: 156237174
Test: atest AccessibilityShortcutTest
Change-Id: Ie15f7fe06644bd35d30d87383b25df81bf29056d
Root cause: FLAG_ACTIVITY_CLEAR_TASK would cause the exist activity are finished and new one items to be started. It causes Live Transcribe main activity goes onStart call of new activity is followed by onStop call of old activity, which cause the mic stopping.
Solution: Remmove the FLAG_ACTIVITY_CLEAR_TASK.
Bug: 156455425
Test: Manual test
Change-Id: Ia5c490cc4816fe41b704ca8ed9dce2891cf44c9b
The disabled a11y service is not removed from the cached service list
when the a11y service package is uninstalled.
To fix it, we have to remove the service from the service list.
Bug: 153507990
Test: manual test & adb shell dumpsys accessibility
Change-Id: Ic1d2ebe3a46faf7237123bcdfca96c79b2c35705
This is a return to the original logic of the unified gesture detector.
Bug: 153584696
Bug: 153715903
Test: atest GestureManifoldTest TouchExplorerTest AccessibilityGestureDetectorTest FrameworksServicesTests:TouchExplorerTest
Change-Id: I384ade72efa2971476561fe6e19cafbebb012c85
Change-Id: Ibaf2fe73632ff89a0f187fe58d60bbfe71da2206
* Uses the atom AccessibilityShortcutReported in westworld.
Bug: 151285965
Test: make statsd_testdrive && ./out/host/linux-x86/bin/statsd_testdrive 266
Change-Id: Iba9d829ae35c7a336c38007101bdddfcd3dc2ddb
For now, this CL is for a conversation on how to give AccesibilityService particular capabilities.
Fixes: 154954447
Test: atest CTSAccessibility*.
Change-Id: I2e47d9a94fda04e60a5eb15a1ec54479c9322b1e
1) Actions are only registered when the service starts. If the locale
changes, the labels need to be translated, so re-register the actions
when this happens.
2) When its shortcut isn't visible the a11y menu action is a no-op. The
list should be an accurate representation of what actions are available.
Pass SystemActions into NavigationBarFragment, which keeps track of the
shortcut availability, to unregister/register the action.
To do this, SystemActions exposes register/unregister to the fragment
and makes SYSTEM_ACTION_ID_ACCESSIBILITY_MENU public.
3) Remove Toggle Split Screen from SystemActions. The trigger isn't
system-level but is rather buried in the Recents UI in a button for each
app, and the a11y user can access this like everyone else.
SystemActionPerformer will still handle the legacy action call in
performSystemAction.
4) Rename "Accessibility Menu" to "On-screen Accessibility Shortcut"
Bug: 152636060, 152635646, 154833492
Test: Manual TalkBack test
Change-Id: I9b037f91c8d3b6f193fc9aee95ef73b7f3fbf315
When the action down motion event contains in the
mTouchExplorationPassthroughRegion, Touchxplorer didn't bypass the
motion event due to enabled multi-finger gesture.
Bug: 152597224
Test: manual test with set mult-finger-gesture enabled non-empty
passthrough region
atest CtsAccessibilityServiceTestCases:TouchExplorerTest
atest FrameworksServicesTests:TouchExplorerTest
Change-Id: Ifef6a4da98aca8144bfd6deaceb1a110cfdbe5df
The bug is happened because the slope between the down event and the
move event of the swipe gesture dispatched from TouchExplorer is
not smooth. So we also ajust the down event position as the moving
event. And we will update the corrupted CTS test case later.
Bug: 152931647
Test: none
Change-Id: I4d4b1ff2975f440dad0babb87d0af1b6ce348f93
* changes:
Rollback chooser menu to version Q behavior for accessibility button (2/n).
Rollback chooser menu to version Q behavior for accessibility button (1/n).
Allow separate Activities to handle the multiple-target case for the hardware and software shortcuts. Migrate from an extra to an explicit class so the Intent dispatch will launch the correct Activity for the particular shortcut.
Bug: 151294664
Test: manual test
Change-Id: I54bb1d3ab91e2757c465e8763786d0234f6d4ea8
As discussed, we:
* Allow apps with INTERACT_ACCROSS_USERS(_FULL) to specify an explicit
user (instead of just USER_CURRENT).
* Introduce new signature permission ACT_AS_PACKAGE_FOR_ACCESSIBILITY
and grant it to sysUI. This permissions allow holders to specify another
package on behalf of which they can perform a11y operations.
This is for toasts since now sysUI renders toasts on behalf of the app
for apps targeting R+.
Bug: 152839254
Test: atest FrameworksServicesTests:AccessibilitySecurityPolicyTest
FrameworksServicesTests:AccessibilityWindowManagerTest
android.widget.cts.ToastTest
Change-Id: I3541045d574518571f348051d53e24ff1a4a67ef
When taking the screenshot, passing the width and height
of the display, and the rotation according to the current
device orientation.
Bug: 153173726
Test: a11y CTS & unit tests
Test: manual test
Change-Id: I19eea2046da282155719b1dfdf9a3f53ad95e13b
Add a private global action to be made public in S. A service can
trigger the event by calling performGlobalAction(10) in R.
Note: Currently 10 is being used by SystemActions for the Accessibility
shortcut. Update ag/10921262 to avoid a conflict.
Bug: 154038741
Test: Tested with modified TalkBack and Youtube play/pause
Change-Id: I3ca5d25948bfb3eb8520030484cb466ec7188784
An a11y service targeting sdk version > Q and requesting a11y button
should be turned on by the Settings when it's assigned to the a11y
shortcut by the user. An a11y button callback is sent to the a11y
service when the user long press the a11y shortcut.
This issue happened when an disabled a11y service is assigned to the
a11y shortcut, and upgraded to the target sdk version > Q. Framework
fails to send the callback and no response when user long press the
shortcut.
Turns on the a11y service and show up a toast to fix this issue.
Bug: 153517972
Test: atest AccessibilityShortcutControllerTest
Change-Id: Ie4fc9bbeaf08ba674cfe6382eab214b2a15c004c
Single tap the a11y button should launch the shortcut target
or chooser activity if there are multiple targets assigned to
the a11y button and user does not specify one.
Rollback the channges of ACCESSIBILITY_BUTTON_TARGET_COMPONENT,
and support a new setting key ACCESSIBILITY_BUTTON_TARGETS for
a11y button to maintain a list of targets which is assigned by
user in settings app.
Also, fix some potential issues, such as, disable a11y shortcut
(this is already not supported) and have more checks to verify
a11y button setting value when an a11y service package updated.
Bug: 152264133
Test: atest AccessibilityUserStateTest
Test: atest AccessibilityShortcutTest
Test: atest AccessibilityButtonSdk29Test
Change-Id: Ief7f44cb85eb75b45dc6ffb6e9a967b792959858
This is relevant when running cts tests in instant mode.
Certain tests were failing in non-system users in instant mode, which is particularlly consquential to auto.
THis fix will be cherry-picked back to their repo
Test: CTSAccessibility*, in both instant/non-instant, and with both system and secondary users.
Bug:146218533
Change-Id: I89937bd552d372adc5d96c51b24d1a2bb4a034e3