If the low threshold is not shown for any reason and we reach the
severe threshold and it does show it will double trigger. This CL
just makes it so both are marked as "shown" if the severe warning
is shown regardless of whether the low warning was shown or not.
Test: runtest systemui
Bug: 116716293
Change-Id: I7fff2d7beba7b37312b9a4c4951a68c3d1f1ba3f
Fixes promise of StatusBarManager#expandSettingsPanel to document what
happens on invalid tile name.
Added test to verify correct behavior.
Change-Id: I057210eb47411cf2a7dfefdd4efe49b96fd33f69
Fixes: 111128728
Test: runtest && manual
In addition to changing imports, this required some changes to use java
7, since that's what the shared lib needs to be for launcher.
See bug for more details on this project.
Test: "atest com.android.systemui.shared.plugins"
build succeeds and all tests pass
Bug: 115877296
Change-Id: Ib79ede0a61664df0ba1a194632a345d2229777fc
Change-Id: Ic0a1178e4f3d6f2addd9bae1c31ec57dffee8eba
Test: Automated tests should pass. Manual testing should also show that notifications behave the same as before (swiping, tapping, dismissing, snapping/unsnapping menu, etc.)
The recent change to NotificationGroupManager to use
HeadsUpManager.isAlerting over the row causes a NPE to occasionally
surface if NonPhoneDependencyTest runs long enough. When it sets up
the listener, it eventually gets a callback that adds a notification and
calls into NotificationGroupManager even though it hasn't had its
dependencies properly set up. This CL fixes that by setting its
HeadsUpManager to the mock.
Test: ensure in all tests that NotificationGroupManager has its
dependencies set when NotificationEntryManager adds a notification
Fixes: 116495228
Change-Id: I7b82eedbf46fde5c8709dd03fdd36059041ef911
- Removing references to SystemServicesProxy (to be removed) for
AM/WMWrapper
- Removing unused code for old nav bar swiping logic, and also unused
and quickstep-incompatible code for dragging in recents
- Removing all event bus logic from outside recents subpackage
- Exposing PipUI component for bridge caller
Bug: 114137554
Test: Can still swipe up
Change-Id: Ibcfbe06acae06ea5950615cabd52243279fee16d
adb command that allows the AOD brightness to be changed:
adb shell am broadcast -p com.android.systemui
-a com.android.systemui.doze.AOD_BRIGHTNESS
--ei brightness_bucket {BUCKET_HERE}
Fixes: 116060647
Test: adb shell am broadcast -p com.android.systemui -a com.android.systemui.doze.AOD_BRIGHTNESS --ei brightness_bucket 2
Test: atest DozeScreenBrightnessTest
Change-Id: I57de0801aac17a3df466899aec2cf4f37a017d33
This change modifies NotificationInfo to call the provided keyguard
callback when the "Stop notifications" button is tapped, rather than
when trying to save the new importance value after the undo timeout.
Test: updated test cases in NotificationInfoTest.
Bug: 111416533
Change-Id: I89b4715d0d41be4587753f554862e51c4e1d43c3
When timing out, we need to update the notifications in
case any of the updates have been blocked.
Change-Id: Idea862f7faae136feea650d292694475973fd3cf
Fixes: 80571494
Test: use test app provided
Test: runtest -x packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/ActivityLaunchAnimatorTest.java
Refactored NavigationBarView's contextual buttons to keep track of just
one button's visiblity with its container group. The visiblity is
determined by the priority of the buttons. For example, accessibility
has the highest priority, if that is visible, no other buttons can take
its place, however if menu button is visible, then rotation can appear
instead.
Bug: 116041410
Test: atest NavigationBarContextTest
Change-Id: Ic0762c7b7121a313b7c08989f9ab761426372c5c
The intent here is to move gesture processing out of NotificationMenuRow and into NotificationSwipeHelper.
Test: Automated tests should pass, and manual experimentation with dismissing/tapping/replying to notifications should work as expected.
Change-Id: Icd32f14769f1b494ecc1dedb2cc37ee129ed21f7
This CL aims to split the ambient pulse logic from the heads up logic as
a lot of the logic is specific to one or the other. This CL introduces
the following major changes.
1. Introduces AmbientPulseManager which manages notifications that pulse
while the screen is dozing or on AOD and manages their lifetime.
2. Ties pulse duration for notifications more tightly with the lifetime.
This means DozeScrimController does not control the pulse time but
instead AmbientPulseManager. This is because previously, having two
separate lifetimes (one for the pulse, one for the notification) caused
some strange issues to occur if one ended before the other.
3. Divide out logic for heads up and ambient pulse, so they are no
longer both tied to shouldPeek in NotificationEntryManager.
4. Multiple naming refactors for readability (e.g. contains ->
isAlerting, mShowAmbient -> mOnAmbient, etc.).
Although this is a refactor, some of the behavior does change in some
places where I thought the current behavior was not intended. In
particular:
* Ambient notifications are no longer marked as seen immediately on
pulsing. We should reserve this for when we are confident the user has
seen the notification.
* Ambient notifications are no longer disabled or snoozed when heads up
notifications are disabled or snoozed respectively.
* Removing/cancelling a notification that is pulsing no longer keeps
the pulse going awkwardly with no notification in the middle. Instead,
the pulse ends (provided it was shown for a minimum amount of time).
Change-Id: I26af6f7e7ad7fa71d2d43f7c4d86fb34551151b0
Test: manual, runtest systemui
Plugins should only run on user builds if explicitly whitelisted.
It's also necessary to hold a signature permission:
com.android.systemui.permission.PLUGIN
Test: atest PluginInstanceManagerTest
Test: atest PluginManagerTest
Test: manually try to install plugin on user build (whitelisted or not)
Bug: 111414690
Change-Id: If17b13f4caef677d641cba84b491b65c8135679b
Reverted ag/4731597 since it was causing issue and instead hides the
menu container when none of its children are visible.
Change-Id: Ie48ef32f8a66392796cb0330faed6dff499bc1b1
Fixes: 114099654
Test: tap around the right edge
There is still one place where status bar needs to notify
NotificationLockScreenUserManager to updatePublicMode (for the
notification showing sensitive info bug).
Otherwise, this commit removes udpatePublicMode from StatusBar and
should have the exact same call semantics as before.
Test: `atest SystemUITests`
Bug: 112656929
Change-Id: I4fe6bc1d6519ae12581f3c17f14c2fcb505eb5f5
I don't see a reason why we would constrain mBarState.addListener to
happen only once, because the whole point is that other classes listen
to those changes as well, and will subscribe unless we mock literally
everything.
Change-Id: Id6aed68c48fbc4f94f78fcd38b9fe0ec83d49c7e
Fixes: 115742174
Test: `atest NotificationStackScrollLayoutTest`
SysUI must send protected broadcasts to avoid system impersonation.
Our tests should also allow these types of broadcasts, otherwise
they will be dropped/skipped on -user builds and functionality
will be broken.
This CL also protects the flashlight broadcast.
Fixes: 110825884
Test: atest com.android.systemui.qs.external.TileServicesTest
Change-Id: I5a3dfc569c1695366e5f0e48cda8a7a32e287e7d
Add some unit tests for NotificationGroupManager testing some basic
functionality and also some of the complex heads up logic.
Bug: 79705024
Test: runtest systemui
Change-Id: I73f01827063d2704a4e1b1d18d479d4e9375447e
Rename NotificationLifetimeExtender.setShouldExtendLifetime to
setShouldManageLifetime. This is more clear in what the logic actually
is and reads better.
Test: runtest systemui
Change-Id: Ic5792322ef0a557812d58f07285acee32cce0c1a
Why?
- This optimization has caused many glitches, it easy to break and
we've done so a few times (technical debt.)
- It's unclear if not calling glClear() is still an optimization.
Most graphics cards actually expect a glClear and are optimized
to discard old frame buffers when the method is invoked
Change-Id: If1bb9b8bf4c907ca907dc1205ad05dabfefeba1b
Fixes: 113286511
Test: manual
Test: shalac@ is keeping an eye on the performance dashboard
Skip QS state change animations when the target view is not fully
visible on screen.
Some tiles require extra time before the status is fully changed and
therefore will be animated later.
Change-Id: I08e76e0fdeab2b260cb7a41a117a6ff484ca3329
Fixes: 111680760
Test: visual and runtest systemui
This CL introduces NotificationLifetimeExtender, an interface for the
various notification managers to implement to say that a notification
should stay around even after being removed. This provides greater
consistency/standardization as opposed to having the same
implementation done differently and scattered throughout different
classes.
Also implements small refactors to try to reduce coupling where possible
(in particular reduce references to NotificationEntryManager) and move
logic to more appropriate locations (in particular move a lot of remote
input logic from NotificationEntryManager to
NotificationRemoteInputManager.)
Test: manual (see below); runtest systemui
* heads up + cancel
* guts active + cancel
* ambient pulse + cancel (UI here is janky even on master)
* have a remote input active + cancel
* have remote history, send, see that the notification stays
Change-Id: I24d345a1f2d8751827e367d1432918b3db7fa5f3
(on AndroidTV there is no need for wallpaper and RAM is wasted)
Bug: 74517029
Test: Push a low resolution wallpaper to the device (adb push new_wallpaper /data/system/users/0/wallpaper),
reboot and check the buffer size for com.android.systemui.ImageWallpaper (adb shell dumpsys SurfaceFlinger)
Change-Id: I992175997ed09360e8fc9c2cabf354fb4fabd1f9
Try to move as much logic up over into stack scroller as possible.
Things that can't move, funnel through NotificationPanel to make the
interface between StatusBar and NotificationPanel more explicit.
Test: Existing tests
Change-Id: I5fa36a9d5d0a8c7f76b9d1843c0733a5758b5838
For consistency with the rest of the system since StatusBarWindowManager
isn't neither a system service or part of Window Manager.
Test: sysuitests
Change-Id: I22f9b929cb3e2fb0c68e1960267855f5e56b2a01