Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d00b0a23 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Fix a11y action "expand notifications" when QS is open"

parents 21f9a66b ec0710e3
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -652,6 +652,14 @@ public class NotificationPanelView extends PanelView implements
        expand(true /* animate */);
    }

    public void expandWithoutQs() {
        if (isQsExpanded()) {
            flingSettings(0 /* velocity */, false /* expand */);
        } else {
            expand(true /* animate */);
        }
    }

    @Override
    public void fling(float vel, boolean expand) {
        GestureRecorder gr = ((PhoneStatusBarView) mBar).mBar.getGestureRecorder();
+1 −1
Original line number Diff line number Diff line
@@ -2313,7 +2313,7 @@ public class StatusBar extends SystemUI implements DemoMode,
            return ;
        }

        mNotificationPanel.expand(true /* animate */);
        mNotificationPanel.expandWithoutQs();

        if (false) postStartTracing();
    }
+3 −3
Original line number Diff line number Diff line
@@ -161,8 +161,8 @@ public class StatusBarTest extends SysuiTestCase {

        mMetricsLogger = new FakeMetricsLogger();
        mDependency.injectTestDependency(MetricsLogger.class, mMetricsLogger);
        mNotificationLogger = new NotificationLogger();
        mDependency.injectTestDependency(NotificationLogger.class, mNotificationLogger);
        mNotificationLogger = new NotificationLogger();

        IPowerManager powerManagerService = mock(IPowerManager.class);
        HandlerThread handlerThread = new HandlerThread("TestThread");
@@ -514,9 +514,9 @@ public class StatusBarTest extends SysuiTestCase {
        mStatusBar.disable(StatusBarManager.DISABLE_NONE, StatusBarManager.DISABLE2_NONE, false);
        verify(mNotificationPanelView).setQsExpansionEnabled(true);
        mStatusBar.animateExpandNotificationsPanel();
        verify(mNotificationPanelView).expand(anyBoolean());
        verify(mNotificationPanelView).expandWithoutQs();
        mStatusBar.animateExpandSettingsPanel(null);
        verify(mNotificationPanelView).expand(anyBoolean());
        verify(mNotificationPanelView).expandWithQs();
    }

    @Test