This way we can restrict server channel in InputFlinger.
Also always use std::move() to move ownership when creating Java object
for InputChannel.
Bug: 167947395
Test: Touch events are still dispatched.
Test: WmTests:DisplayPolicyTests#testUpdateHideNavInputEventReceiver
Change-Id: I7033caf1015ec4bae65beab2c65bdeb4070f4775
This CL also refines the color view logic which checks the system bar
appearance instead of system UI flags.
Bug: 149813814
Test: atest InsetsAnimationControlImplTest InsetsControllerTest
InsetsStateTest InsetsPolicyTest InsetsStateControllerTest
Change-Id: I26d93b3508c84e436133085bd316ade54d00d76a
Our CL [1] used to copy the original surrounding text
in case the text is updated unexpectedly before the
surrounding text retrieval.
Refine the copy logic by:
-. Move copy action to the InitialSurroundingText constructor
-. Apply a deep copy with parcelable, it also avoid the text
span is updated later
[1] I6082a4cae2fcdc4c529dc14e2e5e7a45ab1aae4d
Bug: 160390184
Fixes: 163176179
Test: atest FrameworksCoreTests:EditorInfoTest
Test: atest CtsInputMethodTestCases:EditorInfoTest
Change-Id: I75edcf6046467f2776d62bb38137f9d15dbfab52
The methods other than below are set to oneway.
- with returned value or out argument.
- holds wake lock.
- paired with another sync method (e.g. addToDisplay and remove).
To reduce potential blocking calls.
Bug: 161781274
Test: CtsWindowManagerDeviceTestCases CtsInputMethodTestCases
Change-Id: Ifbf0e73316d4f2194928cdb8be973ec5ef3ec5c6
Add plumbing to get shared timeline data from Surface Flinger to HWUI
and back.
Bug: 162890382
Bug: 162888881
Bug: 162890407
Test: manual using ALOG messages in SF
Change-Id: I85c5eb56d2fa933889518854e7b79b1e65e29af3
This change introduces a new call for clients to request focus on their
embedded views. In order to accomplish this, the owner of the
SurfacePackage sends an input token that can identify the input channel
of the embedded window. This token is forwarded as part of the focus
request.
WindowManager will authenticate the calling window and the relationship
between the host and the embedded window. Once authenticated, the
request will be forwarded to InputDispatcher. InputDispatcher will grant
the focus to the SurfaceControlViewHost if the host window is currently
focused or transfer focus back to the host window if the
SurfaceControlViewHost is focused. Otherwise the request is dropped.
In addition, SurfaceView, the host in this scenario, now overrides the
onFocused function to transfer focus to and from the embedded view.
Test: atest SurfaceControlViewHostTests
Bug: 151179149
Change-Id: Ia95545a60d73db4c03679bce9747d2e275806838
From static analysis, as ViewRootImpl#mWindowAttribute is now a final
object from CL[1] and the object is created when ViewRootImpl initialized
so the object reference should not be changed, it won't be necessary to do
the null check again for some code points.
[1]: I0d749c1abb38520fe8fc477d22d6523f470e9abc
Fix: 168335781
Fix: 168319140
Test: build and check launching app without any exception.
Change-Id: I30e1efb8e52704fbd8c97dc375e7ac253c6a90a8
We send callback when the animation is canceled/reversed due to
the new quest while animating.
Bug: 161669184
Test: atest com.android.systemui.accessibility
atest com.android.server.accessibility.magnification
Change-Id: Iecd5e1bcf0ac097d4271ff0d277872b1dab0c63d
Allow for asynchronous screenshot by sending a ScreenCaptureListener to
handle screenshot callbacks. All existing calls are still synchronous
since the SurfaceControl method will block the caller until the results
from SurfaceFlinger are ready.
Test: power + volume down
Test: adb shell screencap
Bug: 162367424
Change-Id: I6cb5641dc19f32f262e3120949fc30ea104cff89
The frame won't be changed if there is no IWindow#resized or
IWindowSession#relayout. So it can be retrieved from these methods
directly instead of another binder transaction.
And because some parameters are usually used together for layout,
the parameters are consolidated into a new ClientWindowFrames.
That reduces changing the interface in the future if the frame
related information needs to be changed.
Also refine the resize handling in ViewRootImpl to make it easier
to read.
There should be no behavior change by this modification.
Bug: 161781274
Test: WmTests, DialogFrameTests
Change-Id: I9f711ad2023442046fa8582944320b98e7c4ecfa
- Set directly from the system when we enter/leave pip so there's
no chance this gets out of sync
Bug: 167682726
Test: adb shell input keyevent 171 (ensures this still triggers the menu)
Change-Id: I73b4c5b6faebd505bf8e17b4c817b4d600025894
Part of the chain of moving surface size ownership to the client
and making relayout asynchronous. We were already sending Surface
size to the client so it's easy to just use that and avoid
sending an extra result flag.
Bug: 161937501
Test: Existing tests pass
Change-Id: I18a96616d2cf082197fbbd434a737ed77ba40e9c
To handle the transition issue, we would like to add this callbck
both in full-screen and window magnification.
Bug: 161669184
Test: atest FullScreenMagnificationControllerTest
Change-Id: I590871386f885827126a1f21937780d3e6e918d0
- Use the batched receiver when handling back only after the
gesture is recognized (fewer updates)
- Remove some unused code
Bug: 167732711
Test: Back gesture still works
Change-Id: I2b12574a4d6c7f997a8cdc70825ef1bd03669fd8