Revert submission 16468379
Reason for revert: Feature development is moving to T.
Reverted Changes:
Id9b9a8930:[3/n] Camera Compat UI: Add a camera compat contro...
Id6be4a954:Enable a camera app compat control on Large screen...
I083aa6718:[2/n] Camera Compat UI: Add interfaces for client-...
Bug: 206602997
Change-Id: I9ad876043fd61f708a8f468fffd1ef371bfa0866
Changes:
- Listens to changes from the client coming through IActivityClientController#requestCompatCameraControl to ActivityRecord#updateCameraCompatState
- ActivityRecord#updateCameraCompatState sends updated state via TaskInfo to WM Shell
- ITaskOrganizerController#updateCameraCompatControlState to dispatch the user interactions with the control from WM Shell triggers callback to ActivityRecord#updateCameraCompatStateFromUser
- ActivityRecord#updateCameraCompatStateFromUser remembers the user's choice and asks client to apply treatment through ICompatCameraControlCallback
Feature is guarded with config_isCameraCompatControlForStretchedIssuesEnabled
Test: atest WMShellUnitTests:ShellTaskOrganizerTests, atest WmTests:ActivityRecordTests
Bug: 206602997
Change-Id: I083aa6718bd67456bedd9444e9b78740c041f870
Certain top activities will not trigger the "onTaskMovedToFront"
callback which can result in incorrect resizeability
queries. This can happen when a new activity is launched in the top
task.
To avoid this, retrieve the necessary information via the reported
recent tasks by activity manager for a given user id.
Bug: 203044281
Test: Manual using camera application
Change-Id: I61efd4282a2231e6354e5514fc25d7d27005335b
WM delays to destroy window surface if the window is running an exit
animation, and clean it up after the animation finishes. In case the
clean up process was not triggered, we do it before starting an app
transition.
Note that this is a safe guard for potential bugs. The surface shall
be destroyed as soon as an animation finishes, so the clean up should
have been done before an app transition starts.
Bug: 205335975
Test: atest AppTransitionControllerTest
Change-Id: I9c37ab9ebc57ef48827df25ecc52bf09101ad419
Loosen the check on FLAG_RESUME_WHILE_PAUSING in
TaskFragment#startPausing for auto-enter-pip.
Fixed also the round corner radius calculation in WMShell component for
entering PiP transition.
Bug: 198227082
Bug: 202574512
Video: http://recall/-/aaaaaabFQoRHlzixHdtY/bEPWcJSn8iGbLLNg6cM0E3
Test: no auto-enter on quick switch and does on launching new Task,
see video for details
Test: atest PinnedStackTests#testAutoPipOnLaunchingAnotherActivity
Change-Id: I53e62a5f6e663b2d6df8cd0aaa858ff01ef073e8
- This was missed during cherry-pick from master.
Bug: 187720593
Test: Manually verified by building and observing no bootloop.
Change-Id: Ib36186380ce6d786b0f0272b8866b5eab51920c2
Change-Id: Ia25854feed3bb6b037d4510a6b5000d906d27313
Merged-In: Ia25854feed3bb6b037d4510a6b5000d906d27313
Bug: 198593156
Test: manual. capture winscope dump and see it.
PiP Shell Transitions needs to be more robust to pass CTS tests
reliably.
Some changes:
1. DELIVERED_TO_TOP intents don't create a transition since there is
no change to the WM hierarchy. This way the app-launch transition
won't conflict with activityRestartAttempt.
2. If PiP started an expand transition while an enter transition is
ongoing, cancel the enter transition.
a. Additionally, because PiP doesn't resize task until the enter
transition finishes, the expand transition will actually be
a no-op. If we see this pattern, also cancel the enter
transition.
3. When taskVanished, make sure to call any pending finishCallback
because it doesn't allow the running animator to properly finish.
Transition systems require the finish callback to function
properly.
4. Minimize the uses of finishTransition with a sync callback. We
probably need to phase this out because it can conflict with
subsequent startTransition calls (because only 1 sync is supported
at a time).
Bug: 183993924
Test: atest PinnedStackTests
Change-Id: Ieb573032839a2f31b0bb371410484fc93a1714fa
We don't want to allow the client to animate for wallpaper or any
non-app windows.
Bug: 201482129
Bug: 196173550
Test: atest WmTests:AppTransitionControllerTest
#testOverrideTaskFragmentAdapter_noOverrideWithWallpaper
Change-Id: Ic29db59fc9f9695df9c8ba3a6d812ad217cdd641
- The permission is need to assign an Activity to TDA in CarLauncher.
- The permission is used in CarActivityManagerTest.
Bug: 200044674
Test: atest CarActivityManagerTest.
Change-Id: I1d5d520ec44f86c1220e89a0a756757d96676da6
We want to allow organizer to handle the transition in case like
launching split TaskFragments from a non-embedded activity.
Bug: 200496784
Test: atest WmTests:AppTransitionControllerTest
Test: test with demo app to launch split from non-embedded
Change-Id: Iaf1d07c8cf43fa773fede3c031855085147be263
- This is for testing purpose.
Bug: 193247516
Test: build, check boot up
Change-Id: I6c6d860a4b884d8856ede3aa4c73c64a9c568dd5
Merged-In: I6c6d860a4b884d8856ede3aa4c73c64a9c568dd5
(cherry picked from commit d8a331bdcb)
TaskFragment can be empty for either 1. wait for new launch activity, or
2. last activity just removed.
For 1, we want to wait for the activity launch.
For 2, we want to wait for organizer to remove the TaskFragment.
Bug: 196173550
Test: atest WmTests:AppTransitionControllerTest
#testTransitionGoodToGoForTaskFragments
Change-Id: I73ac239ef2e5a75d05af6f6ae97e3f2278ebb4c3
Query the surface flinger property
ro.surface_flinger.primary_display_orientation to determine the
primary display's install orientation. If the window is on the
primary display, then update the transform hint passed on to the
client.
Bug: 196167822
Test: check initial buffer transforms on displays with a different
install orientation
Change-Id: Idf010cd6be73172ba708820f87046c3ba3cf8001
In shell transitions, recents opens on top, but in transient mode
(meaning it doesn't cause the other apps to pause). This means the
other apps should be running un-interrupted. This includes not
taking the IME away.
To handle this, adjust the IME logic so that transient-launching
activities are NOT canBeImeTarget.
Also fix a bug in isVisibleOrAdding where it was using
visibleRequested instead of visible (if you look at the change
history, !hiddenRequested was incorrectly replaced by
visibleRequested instead of visible).
Also fix a bug where a defer/continue of updateImeTarget was
updating the target even when an update was never requested while
it was deferred. This was causing it to be called prematurely
during activitystarter (where global lock is held).
Bug: 193565597
Test: atest ReOpenImeWindowTest SwitchImeWindowsFromGestureNavTest
Change-Id: Ic537d77c8b0e10e80444dd46d7b49e5a9bd63d6c
Adds the USE_CAR_TELEMETRY_SERVICE permission to the allowlist.
This permission is needed for CarTelemetryManagerTest to pass. Otherwise
there will be a security exception whenever the CarTelemetryManager API
is invoked.
Bug: 198309792
Test: atest CarServiceTest:CarTelemetryManagerTest in ag/15752577
Change-Id: I4f95c71f0d9c1891f600e83f7f90f33144300a5c
An app may pass a null surface to MediaProjection#createVirtualDisplay,
and later set the surface on the VirtualDisplay. The display's state
will change from off to on when the surface is set.
When determining if layer mirroring should be started/updated in
DisplayContent, take the presence of the surface/display state
into account, to prevent the app from crashing.
Bug: 197863746
Test: atest WmTests:DisplayContentTests
Change-Id: I01af07fff681aab6fc8235c861375eb79118cbfe
- Add WM_DEBUG_WINDOW_INSETS ProtoLogGroup to use for logging
general Insets logs in WM core.
- Refine InsetsSourceProvider#updateVisibility proto log format
to add insets type information.
- Add InsetsSurceControl#toString to print control target info.
Bug: 197189357
Test: adb shell wm logging enable-text WM_DEBUG_WINDOW_INSETS
Test: atest ProtoLogImplTest \
ProtoLogViewerConfigReaderTest \
WmTests:ProtoLogIntegrationTest \
LogDataTypeTest \
protologtool-tests
Change-Id: I1f01ce4d9fe5cb17f7bd60a424689260682b1dfc
When all windows in the transition is belong to organized TaskFragments,
have the TaskFragmentOrganizer to control the animation on client side.
Bug: 196173550
Test: atest WmTests:TaskFragmentOrganizerControllerTest
Test: atest WmTests:AppTransitionControllerTest
Change-Id: I835467e23863286a5bd34380424cc9eca2c7372f
When intercepting an activity start request, a new split pair
was always created and launch the activity to the side of the
caller activity.
This CL launches the activity on top of the caller activity
if the caller activity is already on the secondary container.
This is needed for the case that the activity is started
into a new Task, or new Task will be escaped from the current
host Task and be displayed in fullscreen.
However, the interception won't work if the activity is started
from another process.
Also adding logs for TaskFragment errors.
Bug: 194997356
Test: manually, start activity with sample app
Change-Id: I268c1dad191cdfdbf48cac84e18f1dfda761b0d3
Before, even if the launcher was not launched, RecentsAnimation would
start the activity in background as invisible. It would cause issue
because ensureVisibility would make it visible because there is no
opaque activity on top, while that may not be collected in any app
transition.
Now, in case the recents activity should be visible, we ignore the
preload recents activity.
Bug: 193565751
Test: pass failed launcher test
Change-Id: I93f5a716177bcbf69f5e4d5915826bd9f61f53a4
This tracks ready state in groups. Currently the groups are
display-contents (to match legacy transitions). The transition
will be considered ready when all groups are ready.
This also adds a couple of inTransition checks in places that
are used by CTS tests.
Bug: 183993924
Test: atest MultiDisplaySystemDecorationTests
Change-Id: Iea81b3c689d948d60aa8e1a2d3bf168723058a2f
Security report shows that this can cause leak token of different app.
Replace the functionality with a callback to the TaskOrganizerController
to restart activity when size compat restart button is clicked.
Bug: 186776724
Test: manually verify the restart button still works
Change-Id: I097b9f02e8435e6765695b9d5a531a4e165bac66
Merged-In: I097b9f02e8435e6765695b9d5a531a4e165bac66
The focused window was determined by looking up the focusable windows
from top to bottom.
In order to switch the focus between the embedded activities in the
same leaf Task without reordering the position of the activities, the
focused app can also be updated based on the window that user was
touched, and the focusable windows that were on other TaskFragment
in the same Task cannot be focused.
Bug: 189385926
Test: changing focused app by touching embedded activity
Change-Id: Id84461572cc768f474ffa313da1c10ff4010408e
Security report shows that this can cause leak token of different app.
Replace the functionality with a callback to the TaskOrganizerController
to restart activity when size compat restart button is clicked.
Bug: 186776724
Test: manually verify the restart button still works
Change-Id: I097b9f02e8435e6765695b9d5a531a4e165bac66
This is required for GTS testing it, rather than having to instrument
GMS Core.
Bug: 182271592
Test: tested as part of other CLs in this topic
Change-Id: Id56e0d206afe0a9069d1510a3dae9a07141fff60