This introduces BackgroundBlurDrawable that does cross-window blurs
The drawable should not be created manually, it should be retrieved
from the ViewRootImpl
Test: manual
Bug: 159712515
Bug: 171916625
Change-Id: I697e93fc95ba3d0a7211b235b1c5d48a1968b939
This is the first step to move the menu to fullscreen, but not quite
yet.
This CL does:
- Move PipMenuView to be attached to SystemWindow, instead of child of
PiP leash
- Use SyncRtSurfaceTransactionApplier to ensure the menu moves along the
PIP leash at the same time when the menu is visible
- Remove setup/destroy code in PipTaskOrganizer with SurfaceViewHost
- Expose Window information to Accessibility services
- Refactor ShellRoot to take in a Layer type instead of windowType
instead
Bug: 161710689
Bug: 170151121
Bug: 169894316
Bug: 152738416
Test: Manual
Change-Id: I73c26f96784b35b9bb9a4bea452df55cf5913278
Expose uid to the CaptureArgs in Java and JNI. The implementation in
native is already merged.
Test: Builds
Bug: 155825630
Change-Id: I66e8870bfbf84a089387b73751cddbac253f9781
These are APIs that have @UnsupportedAppUsage but for which we don't
have any evidence of them currently being used, so should be safe to
remove from the unsupported list.
This is a resubmit of ag/12929664 with some APIs excluded that caused
test failures; see bugs 171886397, 171888296, 171864568.
APIs excluded:
Landroid/bluetooth/le/ScanRecord;->parseFromBytes([B)Landroid/bluetooth/le/ScanRecord;
Landroid/os/Process;->myPpid()I
Landroid/os/SharedMemory;->getFd()I
Landroid/hardware/input/InputManager;->INJECT_INPUT_EVENT_MODE_WAIT_FOR_FINISH:I
Bug: 170729553
Test: Treehugger
Change-Id: I8285daa8530260251ecad6f3f38f98e263629ca7
Update InputConnection#getTextBeforeCursor(int, int) and
InputConnection#getTextAfterCursor(int, int) API to
specify that the paramter {@code n} must be non-negative.
If the IME using the API incorrectly, throw
IllegalArgumentException.
Also update these two APIs that return nullable result (no
behaivor change). For editor App, return null for bad case.
Test: atest BaseInputConnectionTest#testInvalidGetTextBeforeOrAfterCursorRequest
Test: atest InputConnectionWrapperTest#testInvalidGetTextBeforeOrAfterCursorRequest
BUG: 169114026
Change-Id: I95169735198f8363c981a61e20234dfebfd645b1
* changes:
NotificationTopLineView supports layout_height="wrap_content"
Respect the gravity of the NotificationTopLineView.
Remove the smart reply container from the base template; I believe they are never used
A DisplayGroup is a collection of LogicalDisplays which are tied
together for certain behaviors and operations. This CL simply introduces
the class, however in the future it will be used for multi-display power
state work.
Bug: 138328918
Test: manual - build and deploy
Change-Id: I3d736b2758a3363678afc962872fcbe7f4e96806
Adding MANAGE_ACTIVITY_TASKS permission as the replacement, but
still grant the deprecated MANAGE_ACTIVITY_STACKS permission for
app compatibility.
Bug: 157876448
Test: presubmit
Change-Id: I894ee66e058b1024a731d3be4b33b69626451f08
Image suggestions (and other rich content) are not handled the same way
as primitive autofill values. These suggestions are also only applicable
to augmented autofill. Therefore, instead of reusing AutofillType and
AutofillValue, we use a separate code path to insert rich content. A
follow-on change will remove AUTOFILL_TYPE_RICH_CONTENT and the
corresponding code on AutofillValue.
Bug: 168837034
Test: Manual and unit tests
atest CtsAutoFillServiceTestCases:DatasetTest
atest CtsAutoFillServiceTestCases:InlineAugmentedAuthTest
atest CtsAutoFillServiceTestCases:InlineAugmentedLoginActivityTest
Change-Id: I4fa3baf2b545908fc25f3a6e28a7addc7004786b
This patch reverts the earlier patch, ag/11959351, because the correct
solution is aosp/1459888.
When batched input is available, the Choreographer::CALLBACK_INPUT is
scheduled by ViewRootImpl. The callback always runs, even if onStop has
been called. So the earlier patch was invalid.
In practice, what happened was that the batched input was not getting
consumed after FOCUS event was received in the receiver. This was fixed
in aosp/1459888.
The consumption mechanism is complex, so I added a doc explaining how it
works, for future readers.
The newly added test, IncompleteMotionTest, ensures that this regression
does not happen again.
Test: atest IncompleteMotionTest
Bug: 160561987
Change-Id: Ic0a453ebbce1f847de8e9cb87bdffdaf72c12637
These are APIs that have @UnsupportedAppUsage but for which we don't
have any evidence of them currently being used, so should be safe to
remove from the unsupported list.
Bug: 170729553
Test: Treehugger
Change-Id: I4c8fd0006f950de9955242e93968fb0996ceb372
- When an activity is hw accelerated it may be drawing content
backed by a hw buffer, so the drag shadow canvas should match
Bug: 169894807
Test: atest DragDropTest
Change-Id: I35e07d9b3119df674c9e62a83765657ccbe074da
Added View.onReceiveContent() which will invoke the callback if one
is set.
Added View.getOnReceiveContentMimeTypes() to return the MIME types
that the view can receive, removing the getSupportedMimeTypes()
method from the callback interface.
Changed the code to pass MIME types as a String[] instead of a
Set<String> in order to:
* Avoid repeated conversion from Set to array in
onCreateInputConnection.
* Avoid misleading users of the API into using contains() to compare
MIME types (ClipDescription.compareMimeTypes should be used in order to
correctly handle wilcards such as "image/*").
Bug: 170191676
Bug: 152068298
Test: atest CtsViewTestCases:ViewTest
Test: atest CtsViewTestCases:ViewOnReceiveContentTest
Test: atest CtsWidgetTestCases:TextViewOnReceiveContentCallbackTest
Test: atest FrameworksCoreTests:TextViewOnReceiveContentCallbackTest
Test: atest FrameworksCoreTests:AutofillValueTest
Change-Id: Id0c7f8f5fd3c7c44827a62dba1b2b205433e7540
Add mModeSwitchingType to DisplayModeDirector which describes
the allow mode switching type for SurfaceFlinger. This value
is piped to SurfaceFlinger via allowGroupSwitching in
DesiredDisplayModeSpecs.
The value for mModeSwitchingType defaults to
SWITCHING_TYPE_WITHIN_GROUPS, which is the current beheviour in
SurfaceFlinger and it'll be later updated from user settings.
Bug: 161776333
Test: not yet
Change-Id: I851eaee7f86083d97204cf3553e728350c942dfe
TetxClassifier APIs are supposed to call on a worker thread
(@WorkerThread), so there is no reason to enforce a short timeout like
2s.
We are seeing timeouts in some emulator tests.
SuggestConversationActions takes around 3s on the emulator.
I can imagine this can also happen on slow device or the input is
sufficiently long.
Also
- Fixed a bug that forgot to call callback.onFailure() when the caller
is not allowed to see the request.
- mOnServiceFailure should be @NonNull. It is important to invoke
callback.onFailure() to notify the client that the request has just
failed. Currently, there is only callsite that creates the
PendingRequest object and it is not null.
Test: atest -p external/libtextclassifier --all-abi
Test: atest TextClassifierServiceSwapTest
Fixes: 171543321
Change-Id: I24ca3e8d116073650ecf588593fc1e4beba86a45
- Add private window flag INTERCEPT_GLOBAL_DRAG_AND_DROP (protected by
MANAGE_ACTIVITY_STACKS permission) to be considered as a part of the
normal flow for global drag and drops even if the window is not
visible. In addition, the window with the flag receives the clip
data on DRAG_STARTED and the drag surface on DROP. If the window
consumes the drop, then it will relinquish cleanup of the drag surface
from the system.
- Add MIMETYPE_APPLICATION_ACTIVITY for an app to report that they are
starting a global drag of an activity. The associated data must
include an intent with the pending intent and user to launch the
activity for.
- Add a test drag handler on the shell end to receive the drag, setup a
drag layout, and just launch the intent (for now).
Bug: 169894807
Test: atest DragDropControllerTest
Test: atest DragDropTest
Change-Id: I7f5cdca3cf515b693a8f1e507e90e22a670b5fa6
Merged-In: I7f5cdca3cf515b693a8f1e507e90e22a670b5fa6
Signed-off-by: Winson Chung <winsonc@google.com>
Allow capturing protected (DRM) content for animations since the content
will only be rendered back into a protected context. The three
animations are ScreenRotation, SurfaceFreezer, and ColorFade.
For each case, use the setAllowProtected when capturing the content.
ScreenRotation and SurfaceFreezer render the content back on screen
using a SurfaceControl. The Layer automatically gets marked as secure
in SurfaceFlinger since the GraphicBuffer queued is marked as protected.
For ColorFade, the content is rendered with a GL context so we need to
recreate the context with the protected value set.
Test: ColorFade, ScreenRotation, FreeForm with DRM and not DRM content
Fixes: 146180867
Change-Id: I1255d3dd439bcf7b8e4cc4d4a2ce1083b70cb9f1
Added also a AIDL method Launcher would issue when the entering pip
animation is completed on Launcher side and WM should update the task
surface when doing cleanup.
Bug: 143965596
Test: see ag/12838262
Change-Id: I5396f9637b4760df014f63b46543d4f399229bba