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

Commit adb11e07 authored by Adam Powell's avatar Adam Powell Committed by Android (Google) Code Review
Browse files

Merge "Fix ActionBar#isShowing when called before first layout"

parents af0b9c83 f65bfb70
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -830,7 +830,9 @@ public class WindowDecorActionBar extends ActionBar implements
    }

    public boolean isShowing() {
        return mNowShowing && getHideOffset() < getHeight();
        final int height = getHeight();
        // Take into account the case where the bar has a 0 height due to not being measured yet.
        return mNowShowing && (height == 0 || getHideOffset() < height);
    }

    void animateToMode(boolean toActionMode) {