An earlier CL with benchmarks has shown that sending strings as UTF-8
is 50% faster for US-ASCII strings, and still 68% faster for complex
strings referencing higher Unicode planes. (So an improvement in
both cases!)
Since code across the OS still makes heavy assumptions about Parcel
strings typically being UTF-16, we need to carefully migrate
Parcelables by hand, which is what this CLs begins doing.
This is a purely mechanical refactoring with no functional changes.
Bug: 154436100
Test: manual
Exempt-From-Owner-Approval: trivial refactoring
Change-Id: Ia9e581efd7c40269342b7528ca07363deb843c0f
The method will be used in AnrTests to check if the system can support ANR Dialog or not.
Bug: 149510025
Test: atest AnrTests
Change-Id: I7a78be06fcf3c4882931aaea1d330b2cebdc2d84
Test: atest NotificationManagerTest (with CTS cl)
Test: manual - have test app on "all" setting
- get a bubble
- hit "unbubble" from notification
=> no longer bubble
- get update to that notif, it shouldn't bubble
Bug: 154232758
Change-Id: I1611002418cad18ec2426e7d8b4cd4dc93e6df24
Changes to allow CTS test to control organized task so we can have the
tests run the same way sys-ui is driving things now. Control is given
back to sys-ui once the test is done running.
Bug: 149338177
Test: atest CtsWindowManagerDeviceTestCases:SplitScreenTests
Change-Id: I74a03ee3411f5b10ea4e26c1cc3c663dc394dd97
Bug: 152451909
Unit tests often execute server code in the context if a test process.
Such a process does not have the same permissions as formal system
processes. In particular, such a process does not have permission to
invalidate binder caches.
This change disables all binder cache code in the current process.
This means caching is disabled and invalidation never occurs. There
are no permission violations and the test process is also unable to
affect (through cache invalidation) the actual system processes.
Test: Ran a list of atests. Two had security violations before the
change but were okay after the change:
* FrameworksServicesTests
* UserSystemPackageInstallerTest
Ran additional tests to verify no regressions:
* PlatformScenarioTests
* PtsChreTestCases
* BluetoothInstrumentationTests
* UserLifecycleTests
Change-Id: I011ee1eb39b2d52c69b6d5164b64f7418d2bbdd4
Don't let process configuration change application configuration,
but allow to update non-default display configuration while
initialize since the context is focus on different display.
Bug: 148639826
Test: atest PresentationTest ActivityThreadTest AppConfigurationTests
Change-Id: I16ba4eee64406d097b7ff0b7ff5c45175623663a
AutoCorker addresses the situation where big invalidation storms kill
performance but we don't have a way to insert a manual cork around
these update storms.
Bug: 140788621
Test: m
Change-Id: If07d693886fca340c7a18d5a607a4f235aa7107d
Bug: 150310377
Test: atest CtsWindowManagerDeviceTestCases:ActivityViewTest
Test: Used bubbles test app to verify that it's still happy when using
private VDs
Change-Id: I02c6840b1f908a5177c217494de0110f5ce78f7e
- Allow targeting task display area in ActivityOptions.
- Change LaunchParamsController to select preferred task display
area instead of display.
Bug: 152116619
Test: WM CTS and unit tests
Change-Id: I16ab96008e1ce03422f89a0609d3121051261fda
Currently the global configuration is also used as the override
configuration of default display, it is possible that the changed
configuration from relayoutWindow is sent from view root to activity
before handling the relaunch transaction item. So the activity may
receive an unexpected onConfigurationChanged before relaunching.
By enabling the check of activity-handle-able configuration for the
path from view root, the unexpected onConfigurationChanged can be
ignored and proceed to relaunch.
Bug: 145018628
Test: atest ConfigChangeTests#testChangeFontScaleRelaunch
Change-Id: If4c9590583642219ba7b5cd99bbfe84711524cd5
Previously, window token assigns last config to mLastReportedConfiguration
directly, which makes it share the same reference with getConfiguration(),
and blocks all config changes request to clients.
This CL uses Configuration#setTo instead.
fixes: 152227175
Bug: 150251036
Test: atest WindowContextTests
Change-Id: I44143aa558f223eb301e28f2e9110bfd66eac636
- This removes the need for a separate task stack listener and aligns
with other task info change properties
- Also implement equals/hashCode for the token so we can use it in
containers
Bug: 148977538
Test: atest TaskOrganizerTests
Signed-off-by: Winson Chung <winsonc@google.com>
Change-Id: Ie035e6389fdbdc374c1a4b4a684758efa0cb7a9e
The bundle fields may contain custom Parcelables. And Bundle#size
will call unparcel that causes BadParcelableException from
LaunchActivityItem#hashCode and LaunchActivityItem#equals.
Since the bundle fields of LaunchActivityItem may not be significant
for being the accurate identity of the item, the bundle fields can
be treated roughly (empty or not) to avoid unparceling.
Fixes: 153737846
Test: atest FrameworksCoreTests:TransactionParcelTests#testLaunch
Change-Id: I7ec55bbfcffcd47cfb586ede8053ab411891902d
This will allow us to do all/selected/none preferences for
bubbles in settings.
- Feature is on by default
- App is none by default
- Channel is off by default
Test: atest NotificationManagerServiceTest BubbleExtractorTest
Bug: 138116133
Change-Id: Ifad1c22525123354f76959c2d44392a25d56347d
* accountTypesWithManagementDisabled
* disableScreenCapture
For security logging nothing has to be done since the state is
stored in a system property, just changed it so that the logging
will be started after the migration and only events for the
right user are logged.
Also removed the todo about hardening for power cut case, the
risk of additional complexity sees to outweight the benefit.
Bug: 149075700
Test: atest DevicePolicyManagerServiceMigrationTest
Change-Id: I3a58325f2d6f415e51998c5096c5fc123d26602d