Commit Graph

22995 Commits

Author SHA1 Message Date
Jacqueline Bronger
aa61eeefa7 Merge "Add symmetric Getters to PictureInPictureParams" into tm-dev 2022-03-16 14:48:19 +00:00
Miguel Aranda
f9b72c1f9e Merge "Revert "Use compat framework to gate session actions"" into tm-dev 2022-03-16 11:45:14 +00:00
Miguel Aranda
da972b8c71 Revert "Use compat framework to gate session actions"
Revert "Update media flag descriptions"

Revert submission 17161599-b220034304-media-compat

Reason for revert: This seems to cause the break in b/224895002
BUG: 224895002
Reverted Changes:
Ifeecb4e13:Update media flag descriptions
Ie032fe9ec:Use compat framework to gate session actions

Change-Id: I8b309a69282f41b4a45bd82bd3dcc9f85751da7e
2022-03-16 11:34:51 +00:00
Kholoud Mohamed
caf50b5f9d Merge "Add API to check if device policy role qualification is bypassable" into tm-dev 2022-03-16 09:45:21 +00:00
Ming-Shin Lu
cc811102a6 Merge "Add Intrsumentation#resetInTouchMode for instrumenting" into tm-dev 2022-03-16 05:11:24 +00:00
TreeHugger Robot
96a7b9ee75 Merge "Use compat framework to gate session actions" into tm-dev 2022-03-15 17:03:06 +00:00
kholoud mohamed
47020d16c3 Add API to check if device policy role qualification is bypassable
Bug: 220692690
Test: atest android.devicepolicy.cts.DevicePolicyManagerTest
Change-Id: I81b2f7848682d3d23dbd57ca100590d73d6dfd3e
2022-03-15 15:26:44 +00:00
Jacqueline Bronger
dce27c4822 Add symmetric Getters to PictureInPictureParams
- Adds getter to all setters in PictureInPictureParams.Builder
- Changes getAspectRatio and getExpandedAspect ratio to return the
  Rational values instead of floats to ensure symmetry

Bug: 220740459
Test: atest PictureInPictureParamsTest#testPictureInPictureParamsGetters
Test: atest PictureInPictureParamsTest#testPictureInPictureParamsGettersNullValues
Test: atest PinnedStackTests#testFillMaxAllowedActions
Test: atest PinnedStackTests#testRejectExceededActions
Test: atest PinnedStackTests#testCloseActionIsSet
Test: atest PinnedStackTests#testTitleIsSet
Test: atest PinnedStackTests#testSubtitleIsSet
Test: atest PinnedStackTests#testIsSeamlessResizeEnabledDefaultToTrue
Test: atest PinnedStackTests#testDisableIsSeamlessResizeEnabled

Change-Id: Idb06fbf326815181c3e43907dc9c47e5ecc125d0
2022-03-15 12:46:08 +01:00
TreeHugger Robot
78c4ef3d5b Merge "Rename ACTION_UPDATE_DEVICE_MANAGEMENT_ROLE_HOLDER" into tm-dev 2022-03-15 10:19:59 +00:00
Beth Thibodeau
85dddfc3c6 Use compat framework to gate session actions
Adds CompatChange to check if an app posting media controls targets T,
and if so, that app's controls will use PlaybackState actions.
Otherwise, the notification actions will be used.

The MEDIA_SESSION_ACTIONS flag is set to false by default, and can be
used to override this and use session actions for all apps.

Fixes: 220034304
Test: atest com.android.systemui.media
Test: manual - verify in developer settings, override behavior works

Change-Id: Ie032fe9ec8ce7d46b1f9dc8f590ed6fbfa7ee9aa
2022-03-14 19:46:19 -04:00
Frank Wang
cfe0ef548d Merge "Add OnDevicePersonalization system service." into tm-dev 2022-03-14 19:36:53 +00:00
TreeHugger Robot
78a0333f67 Merge "Add a system API to make a package become visible to other package" into tm-dev 2022-03-11 05:21:08 +00:00
Rhed Jao
829792d752 Add a system API to make a package become visible to other package
Expose a system API PackageManager#makeUidVisible for
mainline module to make a package become visible to the caller.

Bug: 222205552
Test: atest AppEnumerationTests
Test: atest PermissionPolicyTest
Ignore-AOSP-First: (for packages/Shell/AndroidManifest.xml) Permission
Change-Id: I6cf322ddfea09a8a4c0c442a6789af4e79d294d7
2022-03-11 10:53:08 +08:00
Frank
81cdede07d Add OnDevicePersonalization system service.
Test: TH
Bug: 218749359
Change-Id: Ib0e921031926c723589d4fd685b2c53407623688
2022-03-10 22:36:57 +00:00
Corina Grigoras
64e22982b0 Merge "Rename READ_MEDIA_IMAGE to READ_MEDIA_IMAGES" into tm-dev 2022-03-10 21:36:38 +00:00
Fabian Kozynski
82b2876457 Merge changes from topics "172251878", "presubmit-am-7890421506ee474b9057d3c5d333e341" into tm-dev
* changes:
  CompatChange to use hidden API in TileService
  Fix loopers in TileServices
2022-03-10 19:09:25 +00:00
Hui Wu
205618682b Merge "CloudSearch API: changes two key names and adds two keys for app pkg name and install count in ExtraInfo" into tm-dev 2022-03-10 17:16:34 +00:00
Fabian Kozynski
af6c54c109 CompatChange to use hidden API in TileService
This adds a new hidden API in StatusBarManager for active
TileService#requestListeningState. That way, we can verify that the
calling package is the same as the one belonging to the tile.
This is enforced using CompatChange for apps that target T+.

Test: atest StatusBarManagerServiceTest
Test: atest TileServicesTest
Test: atest CtsSystemUiHostTestCases
Test: sample app targetting T
Fixes: 172251878

Change-Id: Ic9b8aca55dcfc2b32b018a5308f19e49a933c4c9
2022-03-10 16:47:27 +00:00
Sanjana Sunil
6ae95c15c4 Merge "Set correct storage path for SDK sandbox" into tm-dev 2022-03-10 16:03:19 +00:00
Lorenzo Colitti
99193716f4 Merge "Split out the ethernet API surface and use framework-connectivity-t" into tm-dev 2022-03-10 14:58:25 +00:00
arangelov
54ce996007 Rename ACTION_UPDATE_DEVICE_MANAGEMENT_ROLE_HOLDER
Fixes: 223792001
Test: none
Change-Id: Ifc70fedb4fec926b93aa8931850ac1fcbfdacf0e
2022-03-10 14:40:29 +00:00
Sanjana Sunil
d3eabb0714 Set correct storage path for SDK sandbox
For WebView to run in an sdk sandbox process, Context.getDataDir() needs
to return the shared sandbox storage. This CL sets the value in
LoadedApk while binding the application and modifies bindSdkSandbox API
to take in the client app package name to use in the path.

Test: Manual, check that WebView in sandbox tries to access sandbox
shared storage
Bug: 216284889

Change-Id: I1f8bb7e533d155050710866b80047ec849a98f35
2022-03-10 13:28:39 +00:00
Xiao Ma
218c4d3162 Split out the ethernet API surface and use framework-connectivity-t
Ethernet framework and service source code is going to be moved to
Connectivity mainline module, this CL contains below corresponding
changes to adapt the migration in f/b side:

1. Split out ethernet module-lib APIs to Connectivity module.
   Add the ethernet resource filegroup to tiramisu-updatable-sources
   filegroup as well, build them together. Also update the module-lib
   and system api txt to reflect the APIs change. Remove the hidden
   APIs which are moved to Connectivity module. This removal fixes the
   api inconsistent issue with Tethering/apex/hidden/.

2. Remove EthernetService from SystemServer which will be registered
   from ConnectivityServiceInitializer.

3. Replace the BackgroundThread class(imported from f/b/core/java)
   with the one in the modules-utils-backgroundthread lib, which is
   visible to Connectivity module.

Bug: 210586283
Test: m
Test: atest FrameworksNetTests EthernetServiceTests
Change-Id: I1956848d3248cc56e9841d221e5e4c160bed65a4
2022-03-10 21:22:42 +09:00
Galia Peycheva
f6270e22f7 Merge "Add shouldDockBigOverlays API" into tm-dev 2022-03-10 10:58:53 +00:00
Jay Thomas Sullivan
90f8bc6f9d Rename READ_MEDIA_IMAGE to READ_MEDIA_IMAGES
This permission was only created very recently, and it is unlikely that
any apps are using it yet.

After its creation, it was decided that it should be renamed.

Bug: 223691971
Test: atest CtsPermissionTestCases CtsPermission3TestCases
Change-Id: I9c171161e2c60d38c14e167ea7b7b87bf1235e1b
2022-03-09 23:38:06 -08:00
Charles Chen
2828207a1a Merge "Revert "Revert "Promote startActivityAsUser to SystemApi""" into tm-dev 2022-03-10 03:38:07 +00:00
TreeHugger Robot
3403fc7f1e Merge "Fix compat issue with apps directly calling LoadedApk.makeApplication()." into tm-dev 2022-03-10 02:35:16 +00:00
Hui Wu
e3b56a60a5 CloudSearch API: changes two key names and adds two keys for app pkg name and install count in ExtraInfo
CTS-Coverage-Bug: 210528288
Bug: 223198536
Test: RBE Built redfin-eng and tested on a physical device
Change-Id: Ib7066bcb37618c4e5d751cd0eb0bc1d265831427
Merged-In: Ib7066bcb37618c4e5d751cd0eb0bc1d265831427
2022-03-10 00:15:35 +00:00
Makoto Onuki
169aeafb2d Fix compat issue with apps directly calling LoadedApk.makeApplication().
Unfortuantely, it seems apps may be calling makeApplication() directly,
in which case returning the cached instance would break their expectation.

So let's not return the cached instance for external callers.

Test: Launch the kr.go.kdca.coov-19 app
Fix: 222737976
Change-Id: Idd7d2873d71edad182a7877117745fe021e18a80
2022-03-09 16:14:40 -08:00
Hui Wu
ad36097714 CloudSearch API: adds two keys for app intents in ExtraInfo
CTS-Coverage-Bug: 210528288
Bug: 220741737
Test: RBE Built redfin-eng and tested on a physical device
Change-Id: If2f83f35ff5418086d55fd9799b4586883d955eb
Merged-In: If2f83f35ff5418086d55fd9799b4586883d955eb
2022-03-09 17:47:29 +00:00
Galia Peycheva
ada36900fb Add shouldDockBigOverlays API
This CLs provides the getter API for DockBigOverlays. To better follow
API guidelines, it changes the naming from "*preferDockBigOverlays" to
"*shouldDockBigOverlays"

Bug: 220739302
Test: atest PinnedStackTests#testShouldDockBigOverlaysWithExpandedPip
Change-Id: I25c18531bc1f386b208ab7dde81a8b11a22d03a1
2022-03-09 17:43:41 +01:00
Hui Wu
b8a0d8ca7c Merge "CloudSearch API: change the method from getSource to getCallerPackageName" into tm-dev 2022-03-09 06:14:25 +00:00
Jing Ji
ef439b26ee Merge "Add sub-reasons for the killings from task manager and force-stop" into tm-dev 2022-03-09 05:50:28 +00:00
TreeHugger Robot
fe12ca4320 Merge "Add TEST_MAPPING for trust directories" into tm-dev 2022-03-08 23:54:54 +00:00
Hui Wu
db016f2d73 CloudSearch API: change the method from getSource to
getCallerPackageName

CTS-Coverage-Bug: 210528288
Bug: 220127210
Test: RBE Built redfin-eng and tested on a physical device
Change-Id: Ia7a0930881ca729f000ab38ca224906c8a319cec
2022-03-08 23:41:50 +00:00
Sooraj Sasindran
00e3dabd76 Allow a list of configs to be sent for enterprise slice
Allow a list of configs to be sent for enterprise slice
Allow device owner to set enterprise slice config
Allow enterprise apn to be configured by profile owner

Bug: 217365439
Bug: 222723840
Test: ran CTS tests
Change-Id: I82c159843d0806cbfc5eea602fbd0304e7ff04ac
2022-03-08 19:14:05 +00:00
Yuri Lin
90c8fc93da Merge "Rename getNotificationChannelsBypassingDnd argument to uid" into tm-dev 2022-03-07 22:10:52 +00:00
Lee Shombert
53dd894d42 Merge "Create os/IpcDataCache" into tm-dev 2022-03-07 20:26:05 +00:00
Derek Jedral
b3a502bf63 Add TEST_MAPPING for trust directories
These TEST_MAPPING files indicate presubmit should run atest on trust
specific tests when files are changed in these directories.

Test: local atest
Bug: 221155933
Change-Id: I4f94bba968a68c9c95da30390a9bf2c8ca063b75
(cherry picked from commit 078f38606d)
2022-03-07 18:52:20 +00:00
Yuri Lin
a31bfe2592 Rename getNotificationChannelsBypassingDnd argument to uid
It said "userId" in NotificationManagerService and PreferencesHelper, but in practice was expecting its input to be a uid based on how it's implemented. It also seems most users were already passing in uids (particularly NotificationBackend).

Bug: 220469720
Test: manual verification of settings page, NMSTest, PreferencesHelperTest
Change-Id: I432bdfc7d2986a0a1111c210fd89671524b3885c
2022-03-07 17:53:08 +00:00
TreeHugger Robot
2cb1f3534f Merge "Update javadoc for ACTION_ADMIN_POLICY_COMPLIANCE to include new extras" into tm-dev 2022-03-07 17:20:27 +00:00
Lee Shombert
4f1473c6ac Create os/IpcDataCache
Bug: 219609105

Create os/IpcDataCache as a subclass of PropertyInvalidatedCache.  The
APIs in the new class are the SystemApi for mainline modules.

Note that IpcDataCache.invalidateCache(String) is a new system API,
relative to the list in PropertyInvalidateCache.  The new API is
static, which is the most common use case for invalidateCache calls.

The corresponding CTS test is updated in the next review.  However, it
is also cloned into the current unit test.

Test: * atest FrameworksCoreTests:PropertyInvalidatedCacheTests
 * atest FrameworksCoreTests:IpcDataCacheTest
Change-Id: I83ce97a4154b9065e0686ee99a25c90f955366ff
2022-03-07 08:26:11 -08:00
Yuncheol Heo
9048187a34 Merge "Revert "Expose ActivityOptions.fromBundle() as ModuleApi."" into tm-dev 2022-03-07 15:21:18 +00:00
arangelov
913268bf2c Update javadoc for ACTION_ADMIN_POLICY_COMPLIANCE to include new extras
Fixes: 222677096
Test: none
Change-Id: I0e0e6d6a36f1a63b662b3d9db0d2dea229041768
2022-03-07 14:42:37 +00:00
Kholoud Mohamed
ae758aa7a5 Merge changes from topic "retailDemo" into tm-dev
* changes:
  Allow holders of PROVISION_DEMO_DEVICE to provision a device
  Add new permission PROVISION_DEMO_DEVICE
2022-03-07 14:37:26 +00:00
TreeHugger Robot
cdb9f0c8aa Merge "Skip transfer splash screen if activity is destroying or destroyed" into tm-dev 2022-03-07 08:40:37 +00:00
Charles Chen
b66b090814 Revert "Revert "Promote startActivityAsUser to SystemApi""
This reverts commit 07f7f3ff5b.

Currently, Context#startActivityAsUser(Intent, UserHandle) has
already been a System API. This CL furthur makes
startActivityAsUser with ActivityOptions a System API.
This is enssential to launch an Activity to the secondary display
by setting launched display ID in ActivityOptions.

This also align the behavior of startActivity. We made all versions
of startActivity public APIs.

Bug: 199829817
Change-Id: I334c2a98483e709559162ad64f3b69cbd3b615d2
Test: atest AnnotationTest
CTS-Coverage-Bug: 222189824
2022-03-07 14:17:58 +08:00
Chilun
ec821bed7d Skip transfer splash screen if activity is destroying or destroyed
Sometimes an activity may be destroyed prematurely before the splash
screen animation begins. We can skip transferring the SplashScreenView
to client if the activity is finishing.

Also add more logs for future investigation.

Bug: 221436171
Bug: 170134300
Test: SplashscreenParametrizedTest
      atest ActivityRecordTests SplashscreenTests
Change-Id: I0b5cdbc3d7ff14ad71139c3c5282a0554c40ea1e
2022-03-07 12:00:19 +08:00
Jing Ji
9edb86c985 Add sub-reasons for the killings from task manager and force-stop
Bug: 215222002
Test: Manual - stop FGS from task manager & dumpsys activity exit-info
Test: atest ApplicationExitInfoTest
Test: atest CtsAppExitTestCases
Change-Id: I1519df46685ea3c59ab412a415adbd93ea674f0a
2022-03-04 18:30:45 -08:00
Ming-Shin Lu
32a96b8ad4 Add Intrsumentation#resetInTouchMode for instrumenting
As IWindowManager#setInTouchMode(boolean) will override the global touch
mode state for testing usage, it would be nice to add an API for
restoring the original default touch mode state after the test.

Bug: 220180252
Bug: 220907843
Test: m checkapi
Change-Id: I60909e7da5be3158e2630848f2b6b4b213fc3a01
2022-03-05 00:11:49 +08:00