| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
| |
classes
Bug: 246975184
Test: existing tests
Change-Id: I7732ffb788ce380d3c71206718b24bd30ad827e0
Merged-In: I7732ffb788ce380d3c71206718b24bd30ad827e0
|
| |
|
|
|
|
|
|
|
|
| |
- These were only used for the unbundled launcher build, and Launcher
can reference system code directly now
Bug: 219861883
Test: Builds/Presubmit
Change-Id: I1532f1b853765fb69c5bf46ad5a08230bde00c5f
Merged-In: I1532f1b853765fb69c5bf46ad5a08230bde00c5f
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When the magnification settings mode or config mode transitions,
MagnificationController would
1. Disables the current magnification mode. Then
2. Starts to enable the target magnification mode.
To prevent the magnification change callback send twice during the
mode transition, MagnificationController should only notify the
change of the transitioning target mode and ignore the notifcation
change for the disabling magnification mode.
And when WindowMagnification resets or disables by
WindowMagnificationController#deleteWindowMagnification(),
it should notify source bounds empty when magnification is deleted.
And when FullscreenMagnification resets and the animator is animating,
FullScreenMagnificationController should notify magnification
change.
Bug: 209701404
Bug: 210636326
Test: atest AccessibilityMagnificationTest,
atest WindowMagnificationControllerTest,
atest com.android.server.accessibility.magnification
Change-Id: Ief718614d80177a4a076eddc708a7ecfc4dfb73f
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The listner might invoked twice because we use vsync to
change the magnification spec. When the animation is running,
the posted tasks might executed after animation ended twice.
To fix, we update the source bounds only when it is indeed changed,
which also could reduce the redudant mirroing content operation when
the request is sent consecutively in a short time.
Bug: 214785717
Test: atest AccesibilityMagnificationTest \
--retry-strategy ITERATIONS --max-testcase-run-count 20
Change-Id: I68962b189d8f39f587b717e8125a224e0f67a7e7
|
| |
|
|
|
|
|
|
| |
We add WindowBounds in WindowMagnificationController#dump for debugging.
Bug: 219855496
Test: adb shell dumpsys activity service SystemUIService
Change-Id: I4e848310cf78ab97de350bccb0363ad0b3b7d929
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
After a user perform a11y action, namely moving up/down/left/right, we
have to disable tracking focus functionality.
We refactor #onDrag to a more general term #onMove to cover any move
action which has to disable tracking focus functionality.
Bug: 218935435
Test: atest WindowMagnificationTest
atest WindowMagnificationControllerTest
atest WindowMagnificationManagerTest
Change-Id: I578b301645a08c71e874fe2f4fcf2557202abefd
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For following typing focus feature, we add a
moveWindowMagnifierToPosition method for a window magnifier to move it
to the center of onRectangleOnScreenRequested.
Apart from calling this method to fulfill movement functionality, we can
separate the movement from calling enableWindowMagnification which is a
temporary replacement for movement functionality. Therefore, we can
distinguish whether the it is enabled by the first time or the further
movement behavior. It would help us differentiate the condition whether
we should reset the following typing focus to on/off state. (b/216394179)
Bug: 219654280
Test: atest IWindowMagnificationConnectionTest
atest WindowMagnificationTest
atest WindowMagnificationAnimationControllerTest
atest WindowMagnificationControllerTest
atest WindowMagnificationConnectionWrapperTest
atest WindowMagnificationManagerTest
Change-Id: Iaac3ca6868d948571c1aee54a5f122c9697059d8
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It provides resize api which constraint the minimum and
maximum window size.
Since the magnification window could be an arbitary rectangle,
We need to change the window size and the center based on
the transformation result.
Bug: 188136191
Test: atest WindowMagnificationControllerTest
Change-Id: I63abe89d087988460efc7d0586c5a309e6142768
(cherry picked from commit 9555ceb3945f38e32473b29ab0cebd31f92ecf0b)
Merged-In: I63abe89d087988460efc7d0586c5a309e6142768
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When the foldable is folded /unfolded, we will refetch the display size
to compute the appropriate the window size.
The signal of display size changed is from onConfigurationChanged
which is invoked by Application context. However, we get the display
size from the WindowContxt.
To fix it, we register the callback with the WindowContext based on
the view visiblty, and update the configuration related values before
showing the window.
Test: manual test
atest com.android.systemui.accessibility
Bug: 213958569
Bug: 214318642
Change-Id: Ic98f782f98b9c29f58d08e064985da731e13aa93
|
| |\ |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
There are 3 milestones in this feature.
1. Refactor the callbacks for Accessibility in WindowManagerInternal.
2. Implement this feature in such new architecture.
3. Implement the setting choice in preference page.
This CL is for the 2nd milestone.
We move the window magnification to the typing focus' center position
based on the condition of whether a user takes control or not. We only
make a movement when the control is not taken by a user or we don't
preform the movement for the window magnification.
There are 2 methods for a user to take the control.
1. A user use 1 finger to drag the window magnification.
2. A user use 2 finger to drag the window magnification.
There is 1 method for a user to release the control.
1. When IME is shown, the control would be released.
So, we can decide whether we should make a movement to typing focus
given the condition of who take the control.
Bug: 194668976
Test: atest MagnificationControllerTest
atest WindowMagnificationTest
atest WindowMagnificationControllerTest
atest WindowMagnificationManagerTest
Change-Id: I145f893d412b74c20afe1685449370d1dba99961
|
| |/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
See Design doc: go/b200769372
To make the behavior consistent on the new platform,
The legcay callback,
onMagnificationChanged(MagnificationController controller,
Region region, float scale, float centerX, float centerY)
keep notifying only full-screen magnification change as
before.
To support listening to the magnification changes of all
magnification modes, the service should overide
The new callback proposed in T,
onMagnificationChanged(MagnificationController controller,
Region region, MagnificationConfig config).
TODO: Notify magnifcation change when window magnifier turns off
Bug: 203013925
Test: atest AccessibilityMagnificationTest,
atest MagnificationControllerTest,
atest WindowMagnificationManagerTest,
atest WindowMagnificationControllerTest,
atest FullScreenMagnificationControllerTest,
Change-Id: Ia73195a71f55bb26ef3f2eafce0dc73d8a65583b
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
1. Detect triple-tap and hold gesture.
2. Magnify the content at a user's tap location.
3. Offset the frame to the top-left position about a half of frame size
4. The definition and the implementation of
WindowMagnificationController's getCenterX and getCenterY are different
due to these patches. We need to correct them. (ref: b/207812394)
Bug: 202465806
Test: atest IWindowMagnificationConnectionTest
atest MagnificationControllerTest
atest WindowMagnificationAnimationControllerTest (@Ignore)
atest WindowMagnificationConnectionWrapperTest
atest WindowMagnificationControllerTest
atest WindowMagnificationGestureHandlerTest
atest WindowMagnificationManagerTest
Change-Id: I59bf8a3e35e42c963de1698bec915a4a590e5c5f
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
WindowMagnificationAnimationController
It reverses the relationship between
WindowMagnificationAnimationController and WindowMagnificationController
to simplify the further changes.
1. WindowMagnificationController has
WindowMagnificationAnimationController instance.
WindowMagnificationController is able to know if window
magnifier is animating or not.
If it is animating, the setScale() action or moveMagnifier() will
be interrupted.
2. ControllerSupplier supplies WindowMagnificationController in
WindowMagnification.class.
Bug: 206734640
Test: atest IWindowMagnificationConnectionTest,
atest WindowMagnificationAnimationControllerTest,
atest WindowMagnificationControllerTest,
atest WindowMagnificationTest,
Change-Id: Ibe3471dc99d1aed506b3fd04d12131321d82a07a
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
To extend the magnification API to window magnification mode,
we support enabling the window magnification without animation.
Besides, we also disable the window magnification if the given scale
is less than or equal to 1.0f.
For the screen off scenario, we change to disable the window
magnification without animation.
Bug: 204844820
Test: atest com.android.systemui.accessibility
atest com.android.server.accessibility.magnification
Change-Id: I8a35492776f08ecee353f035a94a16fec8e61218
|
| |
|
|
|
|
|
|
|
| |
The window size depends on the screen size. However, it is too
big for fodlables. We constraint the window size to avoid it.
Bug: 194268185
Test: WindowMagnificationControllerTest
Change-Id: I16b25560e2a7db324433530a9fa4f310fe2fe529
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When the device is folded, the screen size is changed.
We need to compute the magnification frame and its boundary
based on current window metrics. Besides, to keep
the magnified center, we rescale the former center and apply it
to the center of the new magnification frame.
Folding the device also triggers orietation changes, which is
the unexpected case. To avoid handling this case, we also check
whethe it is the window hieght/width exchanging case.
Bug: 185728667
Bug: 185536537
Bug: 180054792
Test: atest WindowMagnificationControllerTest
manually test with follow cases
1. change display size or font size
2. orientate the device
Change-Id: If2a93ad14bf8e07cf149180e639b35fc0bedfd10
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When the mirror window is at the edge of the screen,
it is hard to drag it from the side closed to the edge
because the motion events will be cancelled due to edge-back
gesture detection.
To fix it, we inovke setSystemGestureExclusionRects when the
window layout is changed.
Bug: 189936169
Test: atest WindowMagnificationControllerTest
manually test
Change-Id: I775ce8d6d69aeb3fe1d4433c4e1667bd478b26b3
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The window magnifier is hard to drag when it is at the bottom
of the screen. This is due to that launcher is detecting
swipe-up system gesture.
To fix it, we set the system ui state flag to true when
the window is overlapped with the gesture detection area.
We also update the gesture dection area via OnApplyWindowInsetsListener
Once the area is changed, we will update the flag again if necessary.
In the testing part, we use real WindowManager to verify the
functionality.
Bug: 179648683
Test: atest com.android.systemui.accessibility
manually test and use the following command to check the flag
adb shell dumpsys activity service TouchInteractionService
Change-Id: Ia09bd26b3eb164790614c173594d997d45f4ecdc
|
| |
|
|
|
|
|
|
| |
layout instead of the display size
Bug: 185099320
Test: atest WindowMagnificationController
Change-Id: I764fb870aa18980c07b08dacdaf56bcd598ff2ab
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
To switch magnification mode, a user has to click the magnifcation
button UI. However magnification button UI is visible only when
there is an user touch interaction or the magnification shortcut
triggered event.
However some a11y services like switch-access or voice-access
can only interact with magnification UI by performing
accessibility actions. To make magnification button showing and
able to interact with a user, we also trigger updating
magnification button UI when an accessibility action is performed.
Bug: 179442890
Test: atest WindowMagnificationControllerTest;
atest WindowMagnificationTest;atest MagnificationControllerTest;atest WindowMagnificationManagerTest
Change-Id: I8d762096c9cb6a4421d024a7a1af99b3a48a3462
|
| |
|
|
|
|
|
|
|
|
|
| |
Currently the window bounds of an non-acitivty window depends on
the display area bounds. We need to change to this windowContext
to get the correct windowmetrics for the further display area
feature support.
Bug: 180054792
Test: atest com.android.systemui.accessibility
Change-Id: I0f995f745e7f6cb4ac3616d04c1a65e2e69b8043
|
| |
|
|
|
|
|
|
|
|
| |
To make users aware that the border of the window
is draggable, we bounce the window when tapping it.
Bug: 173159759
Test: WindowMagnificationControllerTest
manually test
Change-Id: I4d5ce07d711389f760dd2a26b6e661068a685440
|
| |\ |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The magnification sale should be consistent between a11y framework
and systemUi. So when a user requests to perfom scale a11y action by
systemUi, We need to handle it in Framework to ensure consistency
of the magnification scale.
Bug: 170791657
Test: atest WindowMagnificationTest WindowMagnificationManagerTest
WindowMagnificationControllerTest MagnificationControllerTest
Change-Id: Iaa34e66f29b320be971d416ce38d770b2265915f
Change-Id: I0598accefd62a8cefd93bda6163ac704fdd96cba
|
| |/
|
|
|
|
|
|
|
|
|
|
|
| |
We apply same accessibility window title to all
magnification-related windows including magnification window and
magnification mode switch.
Bug: 170790760
Bug: 170790395
Test: enable Talkback to test manually and also change the language.
atest MagnificationModeSwitchTest
atest WindowMagnificationControllerTest
Change-Id: I3fedc5c1ac7597005421f61c7159ddfc9a278772
|
| |
|
|
|
|
|
|
|
|
|
|
| |
To prevent MirrorSurfaceView not cleared, when the
denisty is changed, we should call
deleteWindowMagnification and enableWindowMagnification
to reset WindowMagnification instead of just removing
the mirrorview.
Bug: 169149030
Test: atest WindowMagnificationControllerTest
Change-Id: Ie1da5f3556cf23482c562b479f483783e09ded1f
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
To prevent a dragging gesture from misdetecting as a swipe up gesture
when moving the magnification window from the bottom navigation bar,
the magnification window should not overlapped the gesture-detection
region of the bottom navigation bar.
So we have to constrain the position of the magnification window if the
navigation bar mode is NAV_BAR_MODE_2BUTTON or NAV_BAR_MODE_GESTURAL.
Bug: 151394480
Test: atest com.android.systemui.accessibility
Change-Id: If0e3b8bcdcde8ce218e6f5087922783be6ab80c3
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
To support accessibility, we added a11y actions to move
the mirror window and change its scale. We also provide
content description, state description to deliver the
information of the mirror window.
Finally, we update state desceription to send window content change
when changing the scale.
Test: manually test with voice access
atest WindowMagnificationControllerTest
Bug: 143852371
Change-Id: Ia27c5bee39e732609ac1d8e2c7566524e6d7c64c
|
| |\ |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| | |
Screenshot:
b/164005577#comment3
Bug: 164005577
Test: manually test
Change-Id: I00c97d9c99f15a85753b2f3a2b2b099832e6701e
|
| |/
|
|
|
|
|
|
|
|
|
|
| |
Root cause: When the mirror view is not inflated yet, window
magnification will not update its cached dimension values and
rotation even there is a configuration settings changed.
Solution: Not to early return if the mirror view is not inflated
when onConfigurationChanged
Bug: 167973318
Test: atest WindowMagnificationControllerTest
Change-Id: I87290d16f3a10e7b88e8960391b89188443dacc8
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
WindowMagnificationAnimationController provides same
functionality but it runs the animation while
enabling/disabling.
This new patch also fixs NPE excetion that happens
when device is in rotation but mirrorWindow is invisible.
Bug: 161669184 163026794 163035371
Test: atest com.android.systemui.accessibility
atest WindowMagnificationGestureHandlerTest
manual Test: enable window magnification to see it
2. close mirroe window and rotate the device
Change-Id: I4531f5c96ea4b91b287cc8c5ffc4c98fc9611dd5
|
| |
|
|
|
|
|
|
|
|
| |
This reverts commit 1e14e16ac8953e58e03fb6f5648ddf5f20dcb125.
Reason for revert: Breaks fullscreen YouTube playback on wembley
Bug: 163035371
Test: Locally reverted, and now YouTube can play fullscreen on a wembley
Change-Id: I649d651893862b270cb1df14633490748a54bda1
|
| |
|
|
|
|
|
|
|
|
|
|
| |
WindowMagnificationBridge provides same functionality
but it runs the animation while enabling/disabling.
Bug: 161669184
Test: atest com.android.systemui.accessibility
atest WindowMagnificationGestureHandlerTest
manual Test: enable window magnification to see it
Change-Id: Ifdedff335e856ba12209883924032aa545d04738
|
| |
|
|
|
|
|
|
|
| |
Add sourcebounds change callback so that A11yFramwork could know
the center. It is also for magnification public API callback
Bug: 161669184
Test: WindowMagnificationControllerTest
Change-Id: I08c1f9c6f9f5eb540d960c89388b93437d79871a
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
When window magnification is toggled on, the position of window
magnification is not aligned with the one after updating its
layout params. And this bug looks like a transition animation that
is unexpected.
To fix it, we have to offset the position by the margin first
when adding window magnification layout before updating its
layout params.
Bug: 160939052
Test: none
Change-Id: I8e83094d39f33b670e160aaf11c3d09d60dc77bf
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
It takes some time to update the geometry of the mirror window of
window magnification. If the peformance of the device is not so
good, the dragging of window magnification would looks sluggish.
To improve this, we use Choreographer to update the mirror view
geometry. It make the refresh rate sync with display frame
rendering.
Bug: 158264842
Test: atest WindowMagnificationControllerTest
Change-Id: Ia2eaca85ccec90b735dab9114c58a94108cdbed1
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
AsyncTask is deprecated so we use main handler instead to
return callback, onWindowMagnifierBoundsChanged.
And this change also add a null protection and unregister
OnLayoutChangeListener when window magnification is disabled.
And it can prevent null pointer exception.
Bug: 151394161
Bug: 151571627
Test: manual test, atest WindowMagnificationTest
WindowMagnificationControllerTest
Change-Id: I421424582d8bad9e58fe5aca11feb75a31bd5b35
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Window type, TYPE_APPLICATION_PANEL and TYPE_APPLICATION_PANEL, are not
trusted window type while TYPE_ACCESSIBILITY_MAGNIFICATION_OVERLAY
is a trusted window type. ag/10493916
The touch event dispathed within the window that is not trusted
window type might be referred as an obscured event that would make
users unable to turn on a11y settings.
So we change the window type for the windows in window magnification.
Bug: 144075853
Test: adb shell settings put secure window_magnification 1
1. Turn on window magnification
2. Go to a11y menu service setting and click on the switch.
3. Move window magnification overlay above the setting dialog.
4. Click the dialog button within the mirror window.
Change-Id: I9cc2cda7e628b4c2208b5eab1ab1986394088c48
|
| |
|
|
|
|
|
|
|
|
|
| |
Implemented WindowMagnificationConnectionImpl in WindowMagnification.
All requestes should post to main thread to change the UI.
This interface will be created when getting the request from
Accessibility Framework.
Bug: 146400227
Test: manual test
Change-Id: I0b6033dca3d53e7d271b84a5a3008dccf7447d71
|
| |
|
|
|
|
|
|
|
|
|
| |
When the magnification scale is 1x, we can find that position of
the mirror content has a bias with the real content on the screen.
To fix it, we offset the the mirror view with the margin of
mirror surface view.
Bug: 148836275
Test: adb shell settings put secure window_magnification 1
Change-Id: I32e019f44183081819e06e056c080442458e5137
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Because magnification mirror view has transparent border,
the mirror view unable to move close to the screen edges visually.
So we use setTranslationX and setTranslationY to adjust the
location of mirror view to achieve it.
Bug: 146402201
Bug: 148356962
Test: adb shell settings put secure window_magnification 1
Change-Id: I1491ad8113faaa1a559df776f8c6920935dea505
|
| |
|
|
|
|
|
|
|
|
|
|
| |
The postion of mirror window on the screen would be moved when
the device is rotated because of the x and y of layout params
are fixed. To keep mirror window visually unmoved, we have to
update layoutparams of mirror window.
Bug: 147707737
Bug: 146609741
Test: adb shell settings put secure window_magnification 1
Change-Id: I003d578d67c69792c25a580824e933393ef80949
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
1. In the new UX, the new drag handle icon is on the right-bottom of
window magnifier above the mirror SurfaceView. And it would make
the mirror SurfaceView unable to recieve tap events.
To allow taps to go through to the mirror SurfaceView below,
we apply the patch by ag/9987117, applyTapExcludeRegion.
2. Expand the touch area for dragging by adjusting layout.
Bug: 146402201
Test: adb shell settings put secure window_magnification 1
Change-Id: Id59bf8583cf229a5c7292f31a7d04b470793c3f2
|
| |
|
|
|
|
|
|
|
|
| |
To change control UI and make if more flexible, we extract to a single
class to adapt new UI requirement.
Bug: 143745827
Test: MirrorWindowControlTest
Test: WindowMagnificationControllerTest
Change-Id: I0dc141bed293d485357c5347d04d9abd46a010ff
|
| |
|
|
|
|
|
|
|
|
|
| |
1. Get the real display size including the status and navigation bar.
2. Calculate the real position of magnification frame
(i.e. mirror window) based on the magnified region should be limited
by the region of the display.
Bug: 143451908
Test: manual test
Change-Id: I907b005f960bc2e254b73691d7ac8d80cdf92a16
|
| |
|
|
|
|
|
|
|
|
|
| |
This change would update UI when the display size is changed.
In the later changes, we will handle the case for device orientation
changed or a physical display is updated. And we have to keep
the mafnification area unchanged when the UI is updated.
Bug: 144664540
Test: manual test
Change-Id: I7cfac77e1d74c709013c9ed07600051ee9a34097
|
| |
|
|
|
|
|
|
|
|
|
| |
Set the cutout mode of the magnified window to
LAYOUT_IN_DISPLAY_CUTOUT_MODE_SHORT_EDGES,
then this window is allowed to extend into the
cutout areas on the short edges of the screen.
Bug: 145252526
Test: manual test
Change-Id: I7952bd8e0069994d90d3ea207095c827c33c06be
|
|
|
Added support for window magnification as an accessibility feature. The
UI can either be dragged to a new a location or arrow controls can move
the window around.
Test: adb shell settings put secure window_magnification 1
Bug: 136250281
Change-Id: If3098df098f2a1b88b2170e773dccc8f86946abf
|