Currently the recents activity is started by a pending intent created
by launcher. And the sender is system server.
(HIERARCHY_OP_TYPE_PENDING_INTENT in WindowOrganizerController)
If the intent creator doesn't have visible windows, e.g. launcher is
occluded by its another embedded of another package, then the background
launch policy will check whether the intent sender is allowed. But
system server also doesn't have visible windows, which causes
BackgroundActivityStartController#
checkBackgroundActivityStartAllowedBySender to return BalVerdict.BLOCK.
Which will set MOVE_TO_FRONT_AVOID_PI_ONLY_CREATOR_ALLOWS to disallow
moving the target task to front.
See I72a6c22a5fb27aeac52a4e5d46c6a16e28ee6757 for the block policy.
Although currently the recents activity can still move to front because
some places miss to check blocking the launch. Then it is like just
using a security hole.
By adding the background launch permission hint to ActivityOptions,
BackgroundActivityStartController#hasBalPermission will check if the
real caller has permission START_ACTIVITIES_FROM_BACKGROUND. Then
it will pass because the intent sender is system server.
Bug: 341618283
Flag: EXEMPT bugfix
Test: atest NexusLauncherTests: \
com.android.quickstep.TaskAnimationManagerTest
Test: Swipe to minus one screen. Click a news item to Launch chrome.
Swipe from bottom to return to home. There should not have an
error log:
"Without Android 15 BAL hardening this activity would be moved
to the foreground ... only the creator of the PendingIntent
allows BAL. realCallingPackage: android.uid.system:1000 ..."
(from ActivityStarter#logPIOnlyCreatorAllowsBAL)
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:a37161182e76cf445b660d1d4ac138476cfa278e)
Merged-In: I19153f6553c09421bca248d4ff9110d168b34f98
Change-Id: I19153f6553c09421bca248d4ff9110d168b34f98
Flag: NONE - fixing tests
Test: built and ran locally, verified test pass in presubmit
Bug: 224595066
Change-Id: Ifefab1e1696853c5bd816a361314082073ba8a20
Currently launcher gets task stack updates through WM core. Ideally we
would like to migrate into a model where launcher gets these updates
through shell instead.
Test: Manually check that the correct task info is delivered to launcher
from shell
Bug: 341932484
Bug: 344684650
Flag: NONE Just adding a listener, no logic added
Change-Id: Iaf534a4bfee968138d4a4ff282a66e62759af2c0
This change fixes TAPL tests by:
1. Scrolling down to locate PS, in case the scrollbar moves after lock/unlock.
2. Retrying lock/unlock, as sometimes, the request is cancelled by UserManager (if the profile is already in that state)
Bug: 345556016
Test: atest TaplPrivateSpaceTest
Flag: NONE Tapl fix tweak.
Change-Id: Ic0cc3259a2f92065a699d694c47f65c5f68934b8
As gestures start with checking of canStartTrackpadGesture() method, disabling it there disables all touchpad gestures.
Test: RecentsAnimationDeviceStateTest
Flag: NONE these changes are not directly flagged but usage of SYSUI_STATE_TOUCHPAD_GESTURES_DISABLED state is guarded by flag: com.android.systemui.new_touchpad_gestures_tutorial
Bug: 345207568
Change-Id: I0409475a3e006609c6b722cd3b17d75e1ebed939
- Merged DesktopTaskbarRunningAppsController up into
TaskbarRecentAppsController, which is now initialized directly
- The old TaskbarRecentAppsController was effectively a no-op
that was always overridden, so merging the one subclass up makes
things simpler (especially for the follow up CLs which will add
support for switching between Running and Recent tasks using
the same underlying data).
Flag: com.android.launcher3.enable_recents_in_taskbar
Test: TaskbarRecentAppsControllerTest
Bug: 315354060
Change-Id: I8411fb832e5dd3d76201d2694dec0b11bd70bbf9
Attempts to fix a flaky test by ensuring that recents is always cleared before creating a split pair (so the split pair under test is always the same).
Bug: 340935208
Test: testSaveAppPairMenuItemOrActionExistsOnSplitPair(), testSplitTaskTapBothIconMenus()
Flag: TEST_ONLY
Change-Id: Ibc81b90fac531f0e78e93a494ff59073ab5e52cf
The bugs for fixing the removed tests are obsolete, and it was decided to not allocate resources for fixing the tests.
Bug: 190618549, 190729479
Test: presubmit
Flag: NONE it's a test
Change-Id: I1ca3c2c054e4b598c65c86913f0ddbbc711d7f6c
Additionally, let only prediction system provide suggestions, since the
UI surface has been there for a while, adding locally filtered widgets
from app package isn't required.
Bug: 345520128
Test: Unit tests
Flag: EXEMPT bugfix
Change-Id: Ia97f0743fefeae750e07a694bb19d24a5cc11ffe
The test seemed to be failing due to animation issues
(settings cog and Lock text not visible)- b//339179262
Re-enabling the test as those issues are now fixed.
Bug: 322882655
Test: TaplPrivateSpaceTest
Flag: None TaplTest
Change-Id: I4053b9759cd97c721ea576965f57ef309fffaab3
from AppIcon press in overview
Test: Updated unit tests
Flag: EXEMPT not a major feature/ user visible change
Bug: b/326231756
Change-Id: I9e53cd3ec41dd2475ba90ea8fab2fb7a90f5e158
Currently we have logic to only enable input monitor when a trackpad is connected. Tapl tests need to have infrastructure to override that logic
Bug: 335146977
Test: presubmit
Change-Id: Ib7f80c828760f8b5abd7ed2788b246e47fca6e34
Attempt to improve jank and memory regressions by simplifying the view layout of OverviewActionsView.
Bug: 339688091
Bug: 339853741
Test: testSaveAppPairMenuItemOrActionExistsOnSplitPair()
Flag: EXEMPT bugfix
Change-Id: Ib4a7c5a813b221c0a083144e7fb1e1c5f3fedb1c
Fixes: 335146977
Test: Use logging to make sure that input monitor isn't registered in 3 button mode when trackpad is not attached. When it's attached, it's registered upon attachment
Change-Id: I89fc249546945b3adfc4c804eefd53808138168d
When a task is minimised, it becomes invisible but is still running.
WMShell now signals to the launcher when a task's visibility changes.
The task bar takes the visibility into account to know if a running task
is, in fact, minimised.
Test: atest NexusLauncherTests:DesktopTaskbarRunningAppsControllerTest
Flag: com.android.window.flags.enable_desktop_windowing_taskbar_running_apps
Bug: 333872717
Change-Id: Iaff6b1240d354bb3c4de8e4884948acf9bf40112
- Most TaskView method will now loop through taskContainer instead of accessing the first/second
- Moved TaskThumbnailView, showWindowsView, and TaskOverlay to be part of TaskContainer. There are still some TaskOverlay access from TaskThumbnailViewDeprecated that should be remove as we start using TaskThumbnailView
Fix: 339787250
Test: Manual
Flag: EXEMPT refactor
Change-Id: Icfaa4f5eb50582faed01113465335b6d2899f781
- PS1: Android Studio conversion (unformatted, cannot compile)
- PS2: Fix compilation issues and formatting
- PS3: First pass ready for review
- PS4: Minor changes (Remove Consumer, remove unnecessary null-checks)
- PS5: Removed check() around taskContainers, which is now lateinit and should always be initiailzed. Also ensure TaskView is bound before adding to parent.
- PS6: Move a bunch of getters to use .property style
- PS8: Refacoted RecentsView.applyLoadPlan bind logic, to avoid inflating TaksView, bind, add then immediatley remove
- PS10: Turned more functions to express functions; added an extension function
- PS11: Re-order functions, no code changes
- PS12: Reverted unit express function back to {} style
Bug: 339787593
Test: Manual
Flag: NONE
Change-Id: I75c06cf29718d8f258a4124997bcb054f5eb056f
We already reached the limit of 32 flags for an int. To be able to have
more, changing from int to long.
This is needed, as new flags have to be added.
Flag: NONE
Test: Manually running SysUI and Launcher
Test: Unit tests in CL
Bug: 335625543
Change-Id: Iec1d40218264c7c64c50fd09764aa07c0caa7787
- Changed mTaskContainers to a List
- Added an XML for TaskThumbnailView to make it compatible with ViewPool
- Removed mSnapshotViews variable, and streamlined DesktopTaskView binding logic to re-use thumbnailvIew from mTaskContainers or ViewPool
Bug: 249371338
Fix: 251586230
Test: manual
Flag: ACONFIG com.android.window.flags.enable_desktop_windowing_mode DEVELOPMENT
Change-Id: Iab7575e9c36b8ebf3eb62f19f13d75ba671f9f4f
Temporarily disabling the test as there are failures
seen.
Will be renabled, once the RCA of errors is found.
Bug: 339179262
Test: NA
Flag: NA
Change-Id: I4e4a0b9f8b7290e5be27770a4ded2355a2cc74de