TimeSparseArray - used to store UsageEvents - can keep at most one event
per millisecond, which can result in an event being replaced by another
event that occurred close enough that the system records it at the same
millisecond.
Test: atest android.app.usage.TimeSparseArrayTest
Fixes: 73832306
Change-Id: I860a101ab098f65d5c5832758832f43572865690
- Allow slice providers to override grant flow
- Remove overriding caller, that was a terrible idea
- Move where the same app check happens to allow for CTS
Test: CTS
Bug: 69168488
Change-Id: I61c81c0665a08420b7bc83e3660657b62b2cd6a8
This patch addresses a request from the API Council (http://b/74409378).
It defines a new RemoteInput.Source annotation for RemoteInput source
constants.
Bug: 74409378
Test: atest RemoteInputTest
Change-Id: I78a006b6a600ea0c0603b2591d1a29596074a44e
Also, added test api AM.alwaysShowUnsupportedCompileSdkWarning
that allows for forec showing the warning for an activity
component running in a test harness.
Change-Id: I72f6a8425cb6adc6060c70b2165aa82b459769f7
Fixes: 75455658
Test: atest CtsActivityManagerDeviceTestCases:PrereleaseSdkTest
This counts the number of times the app was launched from outside
the app and ignores intra-app activity transitions.
Introduce a new permission for registering to observe app usage.
Fixes a bug where Settings couldn't force the app into another
bucket if it was recently launched.
Bug: 74335821
Fixes: 76100712
Test: Manual test using Settings
Test: UsageStatsTest to verify permission change
Change-Id: Ibd343c1cfa37089a3ac6fc30ba3194e21a9be499
Changed the existing hidden api setPackagesSuspendedAsUser to a system
api setPackagesSuspended that can be called by apps with either
MANAGE_USERS or SUSPEND_APPS permission. Additionally, the suspending
app can now specify optional extra information meant to be used by the
suspended apps and the launcher to deal with this state.
The following other APIs are added:
- isPackageSuspended(): Apps can query whether they are in a suspended
state
- @SystemApi getPackageSuspendedAppExtras(String): Apps with permission
SUSPEND_APPS can get the appExtras passed to PM when suspending the
app.
- @SystemApi setPackageSuspendedAppExtras(String, PersistableBundle):
Apps with permission SUSPEND_APPS can update app extras for a
suspended package.
- getPackageSuspendedAppExtras(): Apps can call to get the appExtras
passed in to PM when they were suspended.
Test: Can be run via:
atest com.android.server.pm.PackageManagerSettingsTests
atest com.android.server.pm.PackageUserStateTest
atest com.android.server.pm.SuspendPackagesTest
Bug: 74336673
Change-Id: I3b9ed2c8478b34ee2e8986f5f5fddb2839d102e3
The new notifications now have different font weights
and colors to make the shade more readable.
Fixes: 69168591
Test: runtest systemui
Change-Id: I0b635724fa122d292841e56efa84aa57fa364300
Add a new AppOp to allow bound system services
such as TelephonyDataServices and potentially
VPN providers to access the IPsec tunnel
management APIs. Since this is not directly
user-facing, and not all System apps should have
this privilege, the access is only granted via
an AppOp or to the system itself.
Bug: 66955045
Test: compilation (still WIP)
Change-Id: I0b0528c75c622d8538baeec019c3672cbed5d899