[SB][Chips] Allow swipe to open shade over status bar chip.
Typically, there's nothing touchable in the status bar. So,
PhoneStatusBarView#onInterceptTouchEvent is only called once for the
DOWN event and never again. When there's no status bar chip, that
behavior won't change.
When there *is* a status bar chip, there are now touchable items in
PhoneStatusBarView. When a gesture is occuring in the chip area,
PSBV#onInterceptTouchEvent will be called for all the events in
the gesture and all of them (DOWN, MOVE, etc.) will be sent to
ShadeViewController (aka NotificationPanelViewController).
If NotificationPanelViewController decides that the gesture is a swipe,
then the event will be intercepted (#onInterceptTouchEvent returns
true). The ongoing call chip will get a CANCEL event (so the chip's
click listener won't trigger) and NPVC will take over showing the shade
expansion animation.
Fixes: 185897191
Bug: 332662551
Flag: com.android.systemui.status_bar_swipe_over_chip
Most important tests:
Test: launcher, start swipe above chip -> verify QQS
expands
Test: in app, start swipe above chip -> verify QQS expands
Test: launcher, start swipe on chip -> verify QQS expands
Test: in app, start swipe on chip -> verify QQS
expands
Test: tap on ongoing call chip -> verify the app that posted the call
notification opens
Test: tap on screen share chip -> verify stop share dialog appears
Test: atest PhoneStatusBarViewTest PhoneStatusBarViewControllerTest
Other tests, pulled from the shade CUJ list:
Test: in immersive app, swipe once -> verify status bar shows. swipe
again -> verify QQS expands (swipe with both 1 and 2 fingers)
Test: keyguard, swipe down from top -> verify QS appears (both 1 and 2
fingers)
Test: launcher, 2 finger swipe down from top -> verify QS expands
Test: launcher, 2 finger swipe down from top with finger on ongoing
call chip -> verify QS expands
Test: HUN displayed, start swipe in different part of status bar ->
verify QQS expands
Change-Id: I555eb27d8f06480fee7f57aebb9aa8ce6b64c1c7
diff --git a/packages/SystemUI/aconfig/systemui.aconfig b/packages/SystemUI/aconfig/systemui.aconfig
index 0314992..23fa40c 100644
--- a/packages/SystemUI/aconfig/systemui.aconfig
+++ b/packages/SystemUI/aconfig/systemui.aconfig
@@ -377,6 +377,16 @@
}
flag {
+ name: "status_bar_swipe_over_chip"
+ namespace: "systemui"
+ description: "Allow users to swipe over the status bar chip to open the shade"
+ bug: "185897191"
+ metadata {
+ purpose: PURPOSE_BUGFIX
+ }
+}
+
+flag {
name: "compose_bouncer"
namespace: "systemui"
description: "Use the new compose bouncer in SystemUI"