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

Commit ae7c8cac authored by Vinit Nayak's avatar Vinit Nayak Committed by Android (Google) Code Review
Browse files

Merge "Enable 3 button nav for taskbar" into sc-v2-dev

parents 6f8747c5 58ffbef8
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -105,7 +105,7 @@ public class NavbarButtonsViewController {
            return true;
        };

        if (mContext.canShowNavButtons()) {
        if (mContext.isThreeButtonNav()) {
            initButtons(mStartContainer, mEndContainer, mControllers.navButtonController);

            // Animate taskbar background when IME shows
+3 −3
Original line number Diff line number Diff line
@@ -161,8 +161,8 @@ public class TaskbarActivityContext extends ContextThemeWrapper implements Activ
        mWindowManager.addView(mDragLayer, mWindowLayoutParams);
    }

    public boolean canShowNavButtons() {
        return ENABLE_THREE_BUTTON_TASKBAR && mNavMode == Mode.THREE_BUTTONS;
    public boolean isThreeButtonNav() {
        return mNavMode == Mode.THREE_BUTTONS;
    }

    @Override
@@ -215,7 +215,7 @@ public class TaskbarActivityContext extends ContextThemeWrapper implements Activ
    }

    public void updateSysuiStateFlags(int systemUiStateFlags, boolean forceUpdate) {
        if (!canShowNavButtons()) {
        if (!isThreeButtonNav()) {
            return;
        }
        mControllers.navbarButtonsViewController.updateStateForSysuiFlags(
+1 −1
Original line number Diff line number Diff line
@@ -61,7 +61,7 @@ public class TaskbarControllers {
     */
    public void init() {
        navbarButtonsViewController.init(this);
        if (taskbarActivityContext.canShowNavButtons()) {
        if (taskbarActivityContext.isThreeButtonNav()) {
            rotationButtonController.init();
        }
        taskbarDragLayerController.init(this);
+1 −1
Original line number Diff line number Diff line
@@ -93,7 +93,7 @@ public class TaskbarDragLayerController {
         */
        public void updateInsetsTouchability(InsetsInfo insetsInfo) {
            insetsInfo.touchableRegion.setEmpty();
            if (mActivity.canShowNavButtons()) {
            if (mActivity.isThreeButtonNav()) {
                // Always have nav buttons be touchable
                mControllers.navbarButtonsViewController.addVisibleButtonsRegion(
                        mTaskbarDragLayer, insetsInfo.touchableRegion);
+1 −1
Original line number Diff line number Diff line
@@ -57,7 +57,7 @@ public class TaskbarKeyguardController {
        mKeyguardSysuiFlags = interestingKeyguardFlags;

        mBouncerShowing = bouncerShowing;
        if (!mContext.canShowNavButtons()) {
        if (!mContext.isThreeButtonNav()) {
            // For gesture nav we don't need to deal with bouncer or showing taskbar when locked
            return;
        }