Adding users from accounts other than the non-system user was not
functional. Simply use the context to launch the CreateUserActivity in
a new task stack.
Also, address test failures where Dependency.get() was being used by
other tests with the wrong context, creating failures in the user
switcher tests. Remove this call from SystemUIDialog and update it
everywhere.
Fixes: 218989709
Fixes: 218824658
Test: atest KeyguardUserSwitcherAdapterTest UserDetailViewAdapterTest KeyguardSecurityContainerTest UserSwitcherControllerTest InternetDialogTest SystemUIDialogTest
Change-Id: Iaceb3dd2add7d2372f9ec646610c8e147c516e63
This was not being used and it was leaking ContentObservers
Test: heapdump, switching between splitshade and not splitshade many
times
Test: atest com.android.systemui.qs
Fixes: 218888308
Change-Id: I63501bf573e006f52379192b7b766283fea40dda
When the hwc supports screen decoration layer, we should:
- create a fullscreen window and put the rounded corners and cutout in
it.
- set ViewRootImpl.setDisplayDecoration(true) for this window.
- set COLOR_MODE_A8 for this window.
- privacy dot should be put in windows with RGB color mode and only
the window that the dot shows in will be shown. So there will be at
most 2 windows(the fullscreen hwc window and the normal window that
the visible dot is in) shown at the same time.
When the hwc not supports screen decoration layer, fallback to the
orignal 2 windows design.
Added a new class DisplayCutoutBaseView and move the common actions of a
cutout view from DisplayCutoutView to it:
- Draw cutouts.
- Handle camera protection.
- Intercepts touches on cutout areas.
Handle the case when the support of hwc screen decorations is changed
due to display change.
Bug: 209498721
Test: atest ScreenDecorationsTest DisplayCutoutBaseViewTest
Change-Id: I286d5d368132381ad56798b794cd18f4ea5d03c5
Only allow the same instance of callback registered once in the
conditions monitor.
Test: atest ConditionMonitorTest#addCallback_withMultipleInstancesOfTheSameCallback_registerOnlyOne
Fix: 218921598
Change-Id: Ibbce271446e4039759e27bf889c4c672ac026c16
Also remove related classes, calls, and resources that were used by QSDetail
and are no longer needed.
Test: atest SystemUITests
Test: TileService cts tests
Test: adb shell cmd statusbar expand-settings
Fixes: 198796184
Change-Id: Ib5c54f197d03794aca35d0305e3e62c7daedb23a
* changes:
[Media SASS] Unregister the muteAwaitConnectionCallback when the Entry stops.
[Media SASS] Choose the correct device icon based on the device attributes.
[Media SASS] Display about-to-connect device names in the media player device chip.
This changelist introduces overriding conditions to Conditions Monitor, which the state of one condition to take precedence over others that are present. To support this feature, the following changes have been made to the Monitor:
- Conditions can now be added and removed to the Monitor post construction.
- Changes to the callbacks and conditions are now handled on the main executor.
- The value for a condition is consulted on every update. Callbacks no longer include the updated value.
Bug: 218744120
Test: atest ConditionMonitorTest
Change-Id: If895732ae9fad120eccabb78207f4555c6236fde
If the DPM locked the device, we always want to show
the "Device locked by admin" message. Previously,
the message would only show if there were trust agents
enabled or a biometric enrolled.
Test: manually lock device with DPM w/o a biometric or trust
agents enabled. See message in bouncer.
Test: atest KeyguardViewMediatorTest
Fixes: 188439183
Change-Id: I0fcee0646da11d4bc63b8224eb4cda2bb6c495c9
- With ag/16678942 the system will now compute multiple appearance
regions for all windows under the status bar, so we need to handle
scenarios where multiple apps can create multiple dark tint areas
Bug: 208717544
Test: atest SystemUITests:LightBarControllerTest
Test: Install MultiAppeareanceRegionTest apk from b/208717544 and
verify that that the multiple dark areas work in multiwindow
Change-Id: I0d8696f6b2fb7793ccbdcbfe7e2520fceb24e5ec
To support RCN use case, allow system apps with the
MEDIA_CONTENT_CONTROL permission to declare that their MediaStyle notification
is for remote playback, and pass in their own device name, icon, and intent to
use in place of the default output switcher that appears on the media controls
Bug: 204910409
Test: atest
Test: manual with test app
Change-Id: Icbfa288c48da9c2ab2fdfdd6b0bfe2b545afaac0
Move width updates into #updateAppearance.
Use numViewsInShelf for smooth width transitions.
Bug: 213480466
Test: add notif, shelf expands
Test: swipe away notif, shelf shrinks
Test: tap hidden/visible part of shelf
=> only visible part of shelf launches full shade
Test: the above in LTR/RTL
Change-Id: Icf5bfa6f901267446bd2dd16b39a6290538541b6
device chip.
Bug: 206614671
Test: atest MediaMuteAwaitConnectionManagerTest
Test: manual: `adb shell am broadcast -a
com.android.systemui.action.SET_FLAG --ei id 904 --ez value 1` to flip
the flag then `adb shell cmd statusbar media-mute-await MuteAwaitDevice
start` and verify that the media player updates to show
"MuteAwaitDevice" as the device with a headphone icon. Video uploaded to
bug showing this interaction.
Change-Id: I4b3dde002904026334f03068dc3574d4b3c5fede
Supports adding a supervised user when configured. Modify the
UserSwitcherController so that all supports dialogs will get the new
"Add user" option if available.
Fixes: 218310361
Test: atest UserSwitcherControllerTest KeyguardUserSwitcherAdapterTest UserDetailViewAdapterTest KeyguardSecurityContainerTest
Change-Id: Ib79dcde2c726cc9508aef667b43662152d047137
Currently we are registering the callback for the second time instead of
removing the callback.
Test: atest DreamOverlayService
Change-Id: I56aa05b52f85ce60b15cb73e9be3a25501534656
We typically get the app icon and name using
`context.packageManager.getApplicationIcon(mediaRoute2Info.packageName)`.
However, this may not work on the receiver device if the receiver
doesn't have the app installed.
The API will allow the caller to provide the app icon and name directly
so that we can ensure the chip on the receiver device is displaying the
necessary app information.
Bug: 216318437
Bug: 217418566
Test: atest MediaTttChipControllerReceiverTest
Test: CTS tests updated in different CL in same topic
Change-Id: Ib5150355a08ae389b218500b235b4bd9c686f919
Remove's config_systemUIServiceComponents from SystemUI's config.xml
and replaces it with a list of Dagger providers that can easily be
defined and customized in code.
This is a step to removing our reliance on reflection and hopefully
lets SystemUI clients better tailor their binary to their needs.
Various other small code tweaks are included to address startup-order
dependent issues that were discovered while writing this CL.
Some startup customization still occurs via XML - one form factor
in particular has an overlay that relies on this. It is my intent
to find a way to move off of that in the future.
Bug: 205725937
Test: manual
Change-Id: I4c207bc9487718eddc21f364e81ec760f286bf30
Removes the easy to refactor Dependency#get calls from the
com.android.systemui.statusbar.phone package. 10 calls are removed
between this cl and the 2 cls in the same topic.
Bug: 218354102
Test: manual && atest SystemUITests
Change-Id: Id57ac5cdd14129913a1d4e32cfbc149c7f9581f7