Allow Bubble overflow to be opened without other active bubbles
Currently you can only access the overflow if you have bubbles in
the stack. There are a bunch of explorations that show accessing
the overflow without the stack (e.g. from taskbar, from people area).
- BubbleData holds onto BubbleOverflow now
- When last bubble is removed, if showing in taskbar/already expanded
& has overflow bubbs, select the overflow.
- No longer null out BubbleStackView when no more bubbles, this
allows overflow to continue to show
- Added tests for overflow behaviour in BubblesTest
Test: atest SystemUITests
Test: manua 1) - produce a bunch of bubbles
- expand the stack, dismiss each bubble
=> when you dismiss the last one, overflow selected
- collapse the stack
=> overflow goes away
2) - have taskbar cl / prototype
- have bubbles in the overflow but no active bubbles
=> observe that taskbar shows the overflow (i.e. sysui
renders the stack in that spot)
Bug: 171322463
Bug: 167413172
Change-Id: I36b9cedc492ace59105dba58c89f9ef92ff4b9e8
This commit is contained in:
@@ -35,6 +35,7 @@ import android.service.notification.StatusBarNotification;
|
||||
import android.testing.AndroidTestingRunner;
|
||||
import android.testing.TestableLooper;
|
||||
import android.util.Pair;
|
||||
import android.view.WindowManager;
|
||||
|
||||
import androidx.test.filters.SmallTest;
|
||||
|
||||
@@ -135,8 +136,9 @@ public class BubbleDataTest extends ShellTestCase {
|
||||
mBubbleB2 = new Bubble(mEntryB2, mSuppressionListener, mPendingIntentCanceledListener);
|
||||
mBubbleB3 = new Bubble(mEntryB3, mSuppressionListener, mPendingIntentCanceledListener);
|
||||
mBubbleC1 = new Bubble(mEntryC1, mSuppressionListener, mPendingIntentCanceledListener);
|
||||
|
||||
mBubbleData = new BubbleData(getContext(), mBubbleLogger);
|
||||
TestableBubblePositioner positioner = new TestableBubblePositioner(mContext,
|
||||
mock(WindowManager.class));
|
||||
mBubbleData = new BubbleData(getContext(), mBubbleLogger, positioner);
|
||||
|
||||
// Used by BubbleData to set lastAccessedTime
|
||||
when(mTimeSource.currentTimeMillis()).thenReturn(1000L);
|
||||
|
||||
Reference in New Issue
Block a user