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

Commit a2056ac7 authored by Caitlin Cassidy's avatar Caitlin Cassidy
Browse files

[Status Bar Refactor] Remove thisFrac from PanelBar#panelExpansionChanged.

`thisFrac` and `frac` always had the same values when logged in
different scenarios, which makes sense: PanelViewController sets its
fraction internally, then calls #panelExpansionChanged with that value.
`thisFrac` is unnecessary, so this CL removes it.

Test: atest+manual
Bug: 200063118
Change-Id: I48d8dc273815f9d5907ee78be0a801b4dc9234b1
parent ff89bfb9
Loading
Loading
Loading
Loading
+2 −5
Original line number Diff line number Diff line
@@ -182,8 +182,7 @@ public abstract class PanelBar extends FrameLayout {
        }
        boolean fullyClosed = true;
        boolean fullyOpened = false;
        if (SPEW) LOG("panelExpansionChanged: start state=%d", mState);
        PanelViewController pv = mPanel;
        if (SPEW) LOG("panelExpansionChanged: start state=%d, f=%.1f", mState, frac);
        mExpanded = expanded;
        mPanelFraction = frac;
        updateVisibility();
@@ -194,9 +193,7 @@ public abstract class PanelBar extends FrameLayout {
                onPanelPeeked();
            }
            fullyClosed = false;
            final float thisFrac = pv.getExpandedFraction();
            if (SPEW) LOG("panelExpansionChanged:  -> %s: f=%.1f", pv.getName(), thisFrac);
            fullyOpened = thisFrac >= 1f;
            fullyOpened = frac >= 1f;
        }
        if (fullyOpened && !mTracking) {
            go(STATE_OPEN);