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

Commit aa4f1311 authored by Johannes Gallmann's avatar Johannes Gallmann
Browse files

Start back gesture tracking in BAC on ACTION_DOWN

Since startBackNavigation is no longer called in onGestureStarted, we
don't have to delay its invocation anymore.

Bug: 301195601
Test: Manual, i.e. verified that predictive back system animations work
      as expected.
Test: BackAnimationControllerTest
Flag: com.android.systemui.predictive_back_delay_wm_transition
Change-Id: I72a7993d596d41bd499bd299f92498e55b0a2e10
parent 20380db5
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -507,10 +507,14 @@ public class BackAnimationController implements RemoteCallable<BackAnimationCont
                        onThresholdCrossed();
                    }
                    mShouldStartOnNextMoveEvent = false;
                } else {
                    if (predictiveBackDelayWmTransition()) {
                        onGestureStarted(touchX, touchY, swipeEdge);
                    } else {
                        mShouldStartOnNextMoveEvent = true;
                    }
                }
            }
        } else if (keyAction == MotionEvent.ACTION_MOVE) {
            if (!mBackGestureStarted && mShouldStartOnNextMoveEvent) {
                // Let the animation initialized here to make sure the onPointerDownOutsideFocus