cancelled.
In the current implementation, when recents animation is cancelled due
to stack order change, window manager replaces the surface with a
snapshot before cancellation. Launcher needs to acquire the snapshot in
order to switch the live tile into snapshot mode, and yet because the
recents animation is cancelled, that snapshot can no longer be acquired
anymore. This change takes care of this "relay" process.
Fixes: 138683199
Test: N/A
Change-Id: I1c11af38c2bdc442e3b45d0b5f0c7e7e37c2b0f0
Test: Open app and immediately swipe up while opening. Verify
Thread prioties in systrace
Test: WindowProcessControllerTests
Fixes: 137881181
Change-Id: Ic1d7403d2a648e6f1d1b6a3d55b56bf37bc57a2c
Parent SurfaceView to a bounds layer that enforces a crop preventing it
from drawing over the surface insets. The bounds layer crop is set to the
surface insets and updated when the parent surface size changes or the
parent surface insets change.
The SurfaceView has a z order relative to the ViewRootImpl surface so
that it can be behind or in front of the main content. If the ViewRootImpl
surface changes, then SurfaceView takes advantage of the
ViewRootImpl.SurfaceChangedCallback to update the relative z order.
Bug: 132205507
Test: go/wm-smoke
Test: test preserve surfaces code path with split screen and ensure relative z is preserved
Test: test SurfaceView apps, YouTube, maps & camera.
Test: try to repro maps pip issue described in bug
Change-Id: I0b2a3612b7e12ba66abb39b6bad4968442743cdd
See go/UnsupportedAppUsage for more details.
These have already been greylisted, however due to bugs/omissions in the tooling have been kept in go/greylist-txt instead of being annotated in the code.
Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@
Bug: 137350495
Test: m
Change-Id: I5aa29a49b193db47aaee4d3a756c17f48cc9f0b1
Part of security fix in I2fdffd8eb4221782cb1f34d2ddbe41dd3d36595c
TCContexts that existed outside a TC session did not have userId
set by the SystemTC. This CL ensures SystemTC always sets the
userId for all TCEvents (and deprecated SelectionEvents).
Bug: 136483597
Test: atest android.view.textclassifier
Manual test ensuring that ConvActions was logging TCEvent with
userId.
Change-Id: Ie2a362f8f4758d5dc0390aeb2dbf23f9d78a378e
Synthesized events consist of injected, split and clamped events.
Instead of letting caller specify it, we fill cursor position fields by
deriving from pointers. Thus we can maintain the property between
pointer coodinates and cursor position. If there is need we can add a
new obtain method later as well anyway.
I decided to update the value for split events because it would be
unnatural to have a out of bound cursor position when a gesture crosses
view boundaries, but ultimately we probably shouldn't split mouse
events. Nevertheless that's out of the scope of this CL and I chose to
be on the safe side at this moment.
Bug: 134788085
Bug: 136607870
Test: atest TooltipTest#testMouseHoverTooltipWithHoverListener
Test: atest MotionEventTest (and select running all candidates)
Test: atest DragDropTest
Change-Id: I4f3dec0f3c4c1ab2ff5cb986b94b0e007d9fe41b
Handle TIMED_OUT better by rescheduling (TODO: give up after N
attempts?)
Fix SYNC_SURFACE_LOST_REWARD_IF_FOUND path to actually go fetch
a new surface.
Bug: 137509524
Test: Injected errors randomly, verified nothing got permanently dead.
Change-Id: Id30f8ad1dd7196041ee84c16c8cf5c814002a6ce
There would be an error if an InputChannel didn't be disposed before
finalized. The client InputChannel created by ViewRootImpl or SystemUI
that would also create an InputEventReceiver to receive input events, and hold
the client InputChannel, so if the InputEventReceiver is going to be disposed,
the InputChannel should be disposed as well.
Test: manual
Bug: 128679213
Change-Id: I24c16f032403e8a982a84a5e0adbfabcdc016f0f
Some apps rely on not updating the window format when changing the
background of the DecorView. To keep the compatibilty with these app we
add only call DecoreView.drawableChanged() when the window background is
changed on app targetting Q and above.
Test: Manually test by lunching Instagram TV and pressing return twice.
The window should aninate with no flickering.
Bug: 136987724
Change-Id: I3593d30dc6f10519008151974e475f0dad86fc64
Some apps rely on not updating the window format when changing the
background of the DecorView. To keep the compatibilty with these app we
add only call DecoreView.drawableChanged() when the window background is
changed on app targetting Q and above.
Test: Manually test by lunching Instagram TV and pressing return twice.
The window should aninate with no flickering.
Bug: 136987724
Change-Id: I3593d30dc6f10519008151974e475f0dad86fc64
- Allow the recents animation runner to request deferring a cancel from
stack order change until the next app transition start without using
a screenshot. This allows launcher to set this state, then start an
activity without a flash due to the animation not finishing immediately
- Always prepare a transition when using the deferred cancel to ensure
an app transition callback
- Handle app transition canceled as well (if canceled, we continue to
cancel recents the animation with/without the screenshot as requested)
- Remove internal lock and use the global WM lock when setting the defer
cancel state
- Renamed a few methods to clarify the deferred cancel flow
Bug: 137196872
Test: atest FrameworksServicesTests:RecentsAnimationControllerTest
Test: atest WmTests:RecentsAnimationTest
Change-Id: Ie8f6f60b6bf6777e36f24749b30f90c8c26ee848
Use ViewRootImpl surface created and destroyed callbacks to set window stopped state
and update the SurfaceView visibility accordingly.
Bug: 132205507
Test: go/wm-smoke
Change-Id: Ie43e3cc81729a153e36fffbefe242d78d8e38222
Allow SurfaceView to be notified when the ViewRootImpl surface changes, is created or
destroyed. The callbacks include a SurfaceControl Transaction object which can be used to
synchronize SurfaceControl changes by the system.
In particular, the transaction will be used to update the relative z order of the SurfaceView
surface when the ViewRootImpl surface changes. WMS is responsible for providing ViewRootImpl a
new surface as well as reparenting its children (SurfaceViews). The transaction will be applied by
the service when it is ready to show the new surface, synchronizing the reparenting with the
relative z update.
Bug: 132205507
Test: go/wm-smoke
Change-Id: Ie5aed430d09cc6d3a0a99f618094b3a50dbaa5cc
Moving InputMethodSystemProperty from android.view.inputmethod to
com.android.server.inputmethod so that it can be accessed only from
the system_server.
Change-Id: I41707a4e5dfe824cbe9e873ec598762d36c64c09
Fix: 137203823
Test: Build and flash
To support non-rectangular visible area for windows, add new APIs
about RegionInScreen in A11yWindowInfo to represent the actual
interact-able area of a window.
Bug: 132146558
Test: a11y CTS & unit tests
Change-Id: I86bb6bc8c567e09f01a3f853a3cffd896ce934c8
When the WindowManager lock is contended, reportSystemGestureExclusionChanged can cause
jank. Making it oneway avoids this.
Fixes: 137650591
Test: make droid
Change-Id: I5d96b7e2225745b146014ad11cafaf0ad9a1b734
Merged-In: I5d96b7e2225745b146014ad11cafaf0ad9a1b734
When the WindowManager lock is contended, reportSystemGestureExclusionChanged can cause
jank. Making it oneway avoids this.
Fixes: 137650591
Test: make droid
Change-Id: I5d96b7e2225745b146014ad11cafaf0ad9a1b734