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

Commit befb9f60 authored by Winson Chung's avatar Winson Chung
Browse files

Revert "Revert "Move binder call to bg thread""

This reverts commit 552d097f.

Reason for revert: Unrelated to the issue

Change-Id: I09c8d5e0128b6ff0d0ed484511afc47ab420f90a
parent 552d097f
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -625,6 +625,7 @@ public class NavigationBar extends ViewController<NavigationBarView> implements
                    }
                }, mainExecutor, bgExecutor);

        mView.setBackgroundExecutor(bgExecutor);
        mView.setEdgeBackGestureHandler(mEdgeBackGestureHandler);
        mNavBarMode = mNavigationModeController.addListener(mModeChangedListener);
    }
+9 −2
Original line number Diff line number Diff line
@@ -88,6 +88,7 @@ import com.android.wm.shell.pip.Pip;
import java.io.PrintWriter;
import java.util.Map;
import java.util.Optional;
import java.util.concurrent.Executor;
import java.util.function.Consumer;

/** */
@@ -97,6 +98,8 @@ public class NavigationBarView extends FrameLayout {

    final static boolean ALTERNATE_CAR_MODE_UI = false;

    private Executor mBgExecutor;

    // The current view is one of mHorizontal or mVertical depending on the current configuration
    View mCurrentView = null;
    private View mVertical;
@@ -349,6 +352,10 @@ public class NavigationBarView extends FrameLayout {
        notifyVerticalChangedListener(mIsVertical);
    }

    public void setBackgroundExecutor(Executor bgExecutor) {
        mBgExecutor = bgExecutor;
    }

    public void setTouchHandler(Gefingerpoken touchHandler) {
        mTouchHandler = touchHandler;
    }
@@ -768,8 +775,8 @@ public class NavigationBarView extends FrameLayout {
        updateSlippery();
        reloadNavIcons();
        updateNavButtonIcons();
        WindowManagerWrapper.getInstance().setNavBarVirtualKeyHapticFeedbackEnabled(
                !mShowSwipeUpUi);
        mBgExecutor.execute(() -> WindowManagerWrapper.getInstance()
                .setNavBarVirtualKeyHapticFeedbackEnabled(!mShowSwipeUpUi));
        getHomeButton().setAccessibilityDelegate(
                mShowSwipeUpUi ? mQuickStepAccessibilityDelegate : null);
    }