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

Commit 77627ace authored by Ioana Alexandru's avatar Ioana Alexandru
Browse files

Go back to using ambientState for footer hiding

Bug: 333445519
Fix: 332612234
Flag: ACONFIG com.android.systemui.notifications_footer_view_refactor TEAMFOOD
Test: close shade when in split shade and see that footer doesn't flash
Change-Id: I6358eaa8104aeffbcba472bc5072b0c579a71c2c
parent fc05d49c
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -594,7 +594,11 @@ public class StackScrollAlgorithm {
        );
        if (view instanceof FooterView) {
            if (FooterViewRefactor.isEnabled()) {
                if (((FooterView) view).shouldBeHidden()) {
                // TODO(b/333445519): shouldBeHidden should reflect whether the shade is closed
                //  already, so we shouldn't need to use ambientState here. However, currently it
                //  doesn't get updated quickly enough and can cause the footer to flash when
                //  closing the shade. As such, we temporarily also check the ambientState directly.
                if (((FooterView) view).shouldBeHidden() || !ambientState.isShadeExpanded()) {
                    viewState.hidden = true;
                } else {
                    final float footerEnd = algorithmState.mCurrentExpandedYPosition