When config_remoteInsetsControllerControlsSystemBars is true,
DisplaySystemBarsController provides its own policy of how system
bars are displayed for specific packages. Currently limited to
only auto versions of Android.
Bug: 149585273
Test: Manual, atest BarControlPolicyTest, atest InsetsPolicyTest,
atest DisplaySystemBarsControllerTest
Change-Id: Ie6b1cc3e2760cbc9e48d62dfbd8bc3e23ffca20c
Merged-In: Ie6b1cc3e2760cbc9e48d62dfbd8bc3e23ffca20c
Creating a new Throwable (and filling in the stack trace) can take
up to 150us. Since we do this on the critical path when sending
over SurfaceControl via binder multiple times, this is too much.
Instead, add an option to pass in callsite manually.
Bug: 159056748
Change-Id: I46c339c15a07192d61c4c546e46f260684a47120
Merged-In: I46c339c15a07192d61c4c546e46f260684a47120
Exempt-From-Owner-Approval: Large scale refactor
When an inline content view is reparented its surface is
getting offset and not being under the view itelf. This is
because the surface views manage the postion of their
surface and are assuming a location based off the window's
surface position. However after a reparenting the inline
content view's surface position becomes relative to that
of the new parent surface view. For example, two surface
views at position (10, 10) being reparented would reslut
in the surface of the parent being at (10, 10) while the
surface of the child being at (20, 20) while both views
would still be at (10, 10).
To address this we are intecepting when an inline content
view's surface is reparented and get a weak reference to
the view that owns the new parent surface. We then position
the inline content view's surface relative to the view that
owns the new parent surface, i.e. we position the surface
such that its location would not change because of the
fact it is being reparented.
While at this make sure the inline content view is marked
as not important for a11y to ernsure the a11y plugins don't
try to click on the view tree in the app's process but
insted on the views in the remote proccess, i.e. on the
embedded view tree.
bug:153826463
Test: atest android.widget.cts.inline.InlineContentViewTest#testReparenting
Change-Id: I2cff4b88d404a740bc447668e948eabccad084d2
We add new test in stage-aosp-rvc-ts-dev for R2, we need make this API
testable.
Bug: 156408900
Test: atest android.autofillservice.cts.inline.\
InlineAugmentedWebViewActivityTest
Change-Id: I27d1227f858aac83b3de1cb8ef719edf177524dc
Merged-In: I27d1227f858aac83b3de1cb8ef719edf177524dc
A11y service cannot get focus of bubbles because it's not a
System owned display. This patch makes System UI owned display
a trusted display. Moreover, this patch refactors the logic to
identify a trusted display by introducing FLAG_TRUSTED and
removes the trusted display check along with supportsSystemDecorations()
because the check has been included in supportsSystemDecorations().
fixes: 155823002
Bug: 152416787
Test: atest DisplayContentTests
Test: atest WindowFocusTests
Test: atest TaskDisplayAreaTests
Test: atest MultiDisplaySystemDecorationTests
Test: atest DisplayTest
Change-Id: Ie684c6488904e5aa8cae166a455c6d55455e5f55
The offset was computed based off the offset represented by
the most recent historical file while we have to use the time
this file was written.
Also now we persist the history on reboot and shutdown,
significantly minimizing the possibility of data loss.
Added test API to emulate reboot of the history to allow for
precise and tightly controlled test to prevent flakes due to
boot time deviations.
Test: atest android.app.appops.cts.HistoricalAppopsTest#testRebootHistory
Fixes:156853195
Change-Id: I4142371f8bc2b1d710cc8c300e7e79cb03764c04
This CL annotates multiple APIs in the HdmiControlManager as Test APIs.
Also creates a Test api wrapper for aidl interface IHdmiControlService.
HdmiPortInfo is the param under test that is also annotated as Test API.
Test: atest android.hardware.hdmi.cts
Bug: 155113872
Change-Id: I58b483eaaa5fe08f90415a7e044c30a28dc7d7c2
They were added to workaround the problem of package-private versions
being added to the stubs, which prevented use of the annotations from
mainline modules.
Having them in the API leads to a different problem -- this version of
the nullability annotations have SOURCE retention. However in the stubs
build we want to have CLASS retention, so that kotlin can make use of
their presence.
This is arguably a much cleaner fix, since having a source-retention
annotation doesn't really make much sense.
Bug: 157010342
Test: m
Change-Id: Id78f00da5b6af2930224a82faa24cb8235362521
Merged-In: Id78f00da5b6af2930224a82faa24cb8235362521
Test APIs are added to CTS to use for SoundTrigger system API test
coverage.
Bug: 152354427
Test: cts-tradefed run cts -m CtsSoundTriggerTestCases
Change-Id: Iea8d5f3095481a54520873b5c5e6976dc272b09c
1. Add a test api in TvInputManager to add hardware device for testing
2. Add Shell permission for TV_INPUT_HARDWARE
3. Add TUNER_RESOURCE_ACCESS permission for TvInput Framework.
Test: atest android.media.tv.cts
Bug: 155114656
Change-Id: I227f13cbf14532d8732729412ae9c2518755ef02
Add a package manager flag so that apps can programmatically query
whether the device have system interface to support the Controls API
Bug: 156096063
Test: manual
Change-Id: I2dab2ecb762b59308c51615137f89733ff42caeb
This change adds a TestApi for simulating a Data Stall to
ConnectivityService. This allows for Data Stalls to be triggered without
having to manipulate the signals used by NetworkMonitor . This also
allows NetworkMonitor to update the ways it detects Data Stalls without
affecting CTS tests for ConnectivityDiagnosticsManager.
Bug: 148032944
Test: atest ConnectivityDiagnosticsManagerTest
Change-Id: Icad439efa2ab4c872c21d3ee6ceaae8c5b49f18d
Merged-In: Icad439efa2ab4c872c21d3ee6ceaae8c5b49f18d
(cherry picked from commit b06463a002)
Chrome will be removing the Application Cache API in future; deprecate
the APIs in WebView which allow Android apps to enable it.
Test: make offline-sdk-docs
Fixes: 156266477
Change-Id: I0feff5289706b5f7985013a18d9cf0e3e6b3ba78
This CL adds isDreaming to DreamMaanger and changes the way it starts a
dream to use IDreamManager.dream()
DreamManager is only used for testing. So far it has been using the
DreamManagerInternal.testDream() API to start the dream. This restricts
the amount of verification that can be done in the dream tests because
it doesn't put the device in a dreaming state -
IDreamManager.isDreaming() is always false.
IDreamManager.dream() puts the device in a dreaming state and enables
better testing.
Bug: 152994058
Test: atest DreamManagerServiceTests
Change-Id: Id4d947e83eabcafa9724764b8d063357c5f2cb49
Introduces new test api to access the background view of status bar and
navigation bar.
Bug: 154720832
Test: atest WindowInsetsPolicyTest
Change-Id: If38d3f57edfbb2631d4c1e47ed5347a332edacfb
This is something clients will need if they register to listen to
DisplayAreas for several features. This will help distinguish the
DisplayAreaInfos.
Test: Builds
Bug: 152114574
Change-Id: If1d14aee070388274afb6a43bc1c631d79fb4b38
If the WindowContainer was revoked from a registered organizer, the
client could still call getLeash to system server and control the leash
for the WindowContainer. Instead, pass the leash back to the client in
onTaskAppeared and onDisplayAreaAppeared. Once the WindowContainer is
revoked from the client, the leash will reference the old
WindowContainer SurfaceControl and will not be able to control the
WindowContainer anymore.
Test: Split screen
Test: DisplayAreaOrganizerTest
Test: WindowOrganizerTest
Bug: 154558563
Change-Id: I1f6eb987a2a3fecfef912a3009ee52989c85ff4b
@SystemApi requires @hide, so @TestApi is needed for these to
be visible to CTS testing
Test: methods visible to CTS test
Bug: 152052560
Change-Id: Icd7f82f3859a1deccd41d2279d8f9722a42df957
Pass DisplayAreaInfo to the client to communicate information about a
specific DisplayArea.
Test: Builds
Bug: 152114574
Change-Id: Iec53ec57d1e5e892d66a1da0bd48b75f91965d20
Adds a new Setting for the user to show or hide power menu content
(cards & passes, controls) when the device is locked (secured). A value
of 0 (default) means hide content and a value of 1 means show.
The setting updates from the notification in the following way:
* If Secure.LOCK_SCREEN_SHOW_NOTIFICATIONS is 1 AND
Secure.LOCK_SCREEN_ALLOW_PRIVATE_NOTIFICATIONS is 1, the new setting is
set to 1 (the user has allowed sensitive content).
* If at least one of those settings is 0, the new setting is set to 0
(the user has not allowed sensitive content).
* If the settings are not set, the new setting is not set.
Test: build
Test: manual with adb
Bug: 152212779
Change-Id: If6d9436f633bc45330956372ea7f8a40ed22ed52
* Add @TestApi isFactoryResetProtectionPolicySupported()
to DevicePolicyManager which returns whether factory
reset protection policy is supported on the device.
Bug: 153696811
Test: atest com.android.cts.devicepolicy.OrgOwnedProfileOwnerTest#testFactoryResetProtectionPolicy
Change-Id: Id0bd6cdacf33f0fb2f795e1ead5127b79f42960e
For testing the accessibilityNodeInfo constructor methods, making this
method, AccessibilityNodeInfo#getSourceNodeId, to become a testing API.
Bug: 154163930
Bug: 154163953
Test: a11y CTS & unit tests
Change-Id: I9a2ff665996e28d6d5770723d98b49f96eab1f50
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
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