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

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

Merge "Set overview orientation for all nav modes" into ub-launcher3-rvc-dev

parents f7c768c7 e03ad7ed
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -53,14 +53,17 @@ final class AppToOverviewAnimationProvider<T extends StatefulActivity<?>> extend
    private final BaseActivityInterface<?, T> mActivityInterface;
    // The id of the currently running task that is transitioning to overview.
    private final int mTargetTaskId;
    private final RecentsAnimationDeviceState mDeviceState;

    private T mActivity;
    private RecentsView mRecentsView;

    AppToOverviewAnimationProvider(
            BaseActivityInterface<?, T> activityInterface, int targetTaskId) {
            BaseActivityInterface<?, T> activityInterface, int targetTaskId,
            RecentsAnimationDeviceState deviceState) {
        mActivityInterface = activityInterface;
        mTargetTaskId = targetTaskId;
        mDeviceState = deviceState;
    }

    /**
@@ -73,6 +76,7 @@ final class AppToOverviewAnimationProvider<T extends StatefulActivity<?>> extend
        activity.<RecentsView>getOverviewPanel().showCurrentTask(mTargetTaskId);
        AbstractFloatingView.closeAllOpenViews(activity, wasVisible);
        BaseActivityInterface.AnimationFactory factory = mActivityInterface.prepareRecentsUI(
                mDeviceState,
                wasVisible, (controller) -> {
                    controller.dispatchOnStart();
                    controller.getAnimationPlayer().end();
+0 −3
Original line number Diff line number Diff line
@@ -300,9 +300,6 @@ public abstract class BaseSwipeUpHandler<T extends StatefulActivity<?>, Q extend
            if (TestProtocol.sDebugTracing) {
                Log.d(TestProtocol.PAUSE_NOT_DETECTED, "BaseSwipeUpHandler.2");
            }
            ((RecentsView) createdActivity.getOverviewPanel())
                    .setLayoutRotation(mDeviceState.getCurrentActiveRotation(),
                            mDeviceState.getDisplayRotation());
            initTransitionEndpoints(InvariantDeviceProfile.INSTANCE.get(mContext)
                .getDeviceProfile(mContext));
        }
+1 −1
Original line number Diff line number Diff line
@@ -331,7 +331,7 @@ public abstract class BaseSwipeUpHandlerV2<T extends StatefulActivity<?>, Q exte
        // as that will set the state as BACKGROUND_APP, overriding the animation to NORMAL.
        if (mGestureState.getEndTarget() != HOME) {
            Runnable initAnimFactory = () -> {
                mAnimationFactory = mActivityInterface.prepareRecentsUI(
                mAnimationFactory = mActivityInterface.prepareRecentsUI(mDeviceState,
                        mWasLauncherAlreadyVisible, this::onAnimatorPlaybackControllerCreated);
                maybeUpdateRecentsAttachedState(false /* animate */);
            };
+1 −1
Original line number Diff line number Diff line
@@ -83,7 +83,7 @@ public final class FallbackActivityInterface extends

    /** 6 */
    @Override
    public AnimationFactory prepareRecentsUI(
    public AnimationFactory prepareRecentsUI(RecentsAnimationDeviceState deviceState,
            boolean activityVisible, Consumer<AnimatorPlaybackController> callback) {
        DefaultAnimationFactory factory = new DefaultAnimationFactory(callback);
        factory.initUI();
+5 −1
Original line number Diff line number Diff line
@@ -32,6 +32,7 @@ import android.view.animation.Interpolator;
import androidx.annotation.Nullable;
import androidx.annotation.UiThread;

import com.android.launcher3.BaseDraggingActivity;
import com.android.launcher3.BaseQuickstepLauncher;
import com.android.launcher3.DeviceProfile;
import com.android.launcher3.Launcher;
@@ -118,8 +119,11 @@ public final class LauncherActivityInterface extends
    }

    @Override
    public AnimationFactory prepareRecentsUI(
    public AnimationFactory prepareRecentsUI(RecentsAnimationDeviceState deviceState,
            boolean activityVisible, Consumer<AnimatorPlaybackController> callback) {
        ((RecentsView) getCreatedActivity().getOverviewPanel())
                .setLayoutRotation(deviceState.getCurrentActiveRotation(),
                        deviceState.getDisplayRotation());
        DefaultAnimationFactory factory = new DefaultAnimationFactory(callback) {
            @Override
            public void setShelfState(ShelfAnimState shelfState, Interpolator interpolator,
Loading