We used the original down location while injecting all down events.
It accidently increases the velocity in the beginning and cause
Launcher detect the gesture into unexpected state.
Test: manually
Bug: 162521649
Change-Id: I527f3e785ee1082f86ef1a60e57ccd825bdfeae9
Throughout the gesture system we scale the touch slop radius to the number of fingers that are down at any given moment. Therefore the correct value to
trigger two-finger passthrough should be 2 * mTouchSlop.
This should make three-finger taps less problematic.
Bug: 163438921
Bug: 162521649
Test: manual
Change-Id: I4b36b5575bf11ad767d83effd6292dc84eadb27d
Change-Id: I9fb9d58ef679151c9fc595bcb375f6209ea3a5af
Change-Id: Ibcae2a5a3fde37b97859165efabf2b0df13ded9b
We inject the down events from where we detect the 3-finger swipe
gesture. It may not trigger the A11y Button if the event is not inside
the system gesture detection area.
We inject the original down location to injection all down events.
Bug: 166187595
Test: manually test
Change-Id: I0c0f84047fc24e40724332d51d7e3dc414bd0186
We accidentky checked invalid pointers down position.
In stead of checking all pointers, we check the pointer ids
from the motion event.
Bug: 165576902
Test: manually test
atest TouchExplorerTest
Change-Id: Id530bf4b760351215726b2afd781433b590f57ce
1) Only start delegating upon first move event, if all three fingers went down on the bottom edge.
2) The previous logic only required one finger to be in the edge boundary. It now requires all fingers to be in the edge boundary.
Bug: 162521649
Test: manual
Change-Id: I829c463c63b384642d129ff3b5ccdb0db816ddcd
This does not apply when transitioning from touch exploration to dragging.
Bug: 162521649
Test: manual
Change-Id: I92022ca0359040a6563e6a48c110face574dc9df
The code was trying to set the location of the drag, but MotionEvent doesn't behave consistently when setting a single location to a multi-touch event.
All that's needed is to select the correct pointer, so removing messing with the location gives more consistent behavior.
Bug: 163105030
Change-Id: I6c315cf0a1e48847cc778ec8c34b382d13ce3555
Test: Manually testing at this point of the passthrough, and relying on treehugger.
Range check index into motion event x and y before using it.
Bug: 163107812
Test: Relying on treehugger. I can't reproduce the crash, so I'm just adding checks.
Change-Id: I4ac5023ef9b5c101748b870a01a425a1365fb85c
1. Rename isClientInWhitelist to isClientInAllowlist
See https://source.android.com/setup/contribute/respectful-code for
reference
Bug: 162536543
Test: Build & run
Change-Id: I915e09e4e64d5c268630cec2d0ef05ea0592fd6f
Merged-In: Ibbd97bf31915d59b5110cbcc8f2126f7a7221060
java.util.NoSuchElementException: Death link does not exist
when linkToDeath has remote exception, unlinkToDeath will fail and
throw NoSuchElementException, catch it in AbstractAccessibilityServiceConnection
to avoid system server crash.
Bug: 157580692
Test: manual
Change-Id: I42ce3a458e04539d76555679279d1368e0c61ae0
The properties populated when double-tap and hold is detected is not
cleared after interaction end. It cuases an offset on hoverevent.
Bug: 160463594
Test: atest TouchExplorerTest
Change-Id: Id5115fe64e4bda9c7657f67bef62290858442de9
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