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

Commit 36e0fd91 authored by Iris Yang's avatar Iris Yang Committed by Android (Google) Code Review
Browse files

Merge "Set launch display id to an action performed on BaseQuickStepLauncher"

parents d941d02d 55f74d67
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -39,6 +39,7 @@ import android.hardware.SensorManager;
import android.hardware.devicestate.DeviceStateManager;
import android.os.Bundle;
import android.os.CancellationSignal;
import android.view.Display;
import android.view.View;
import android.view.WindowInsets;
import android.window.SplashScreen;
@@ -509,6 +510,9 @@ public abstract class BaseQuickstepLauncher extends Launcher
                    activityOptions.options, mLastTouchUpTime);
        }
        activityOptions.options.setSplashScreenStyle(SplashScreen.SPLASH_SCREEN_STYLE_ICON);
        activityOptions.options.setLaunchDisplayId(
                (v != null && v.getDisplay() != null) ? v.getDisplay().getDisplayId()
                        : Display.DEFAULT_DISPLAY);
        addLaunchCookie(item, activityOptions.options);
        return activityOptions;
    }
+4 −0
Original line number Diff line number Diff line
@@ -38,6 +38,7 @@ import android.content.res.Configuration;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.Display;
import android.view.SurfaceControl.Transaction;
import android.view.View;
import android.window.SplashScreen;
@@ -256,6 +257,9 @@ public final class RecentsActivity extends StatefulActivity<RecentsState> {
                ActivityOptionsCompat.makeRemoteAnimation(adapterCompat),
                onEndCallback);
        activityOptions.options.setSplashScreenStyle(SplashScreen.SPLASH_SCREEN_STYLE_ICON);
        activityOptions.options.setLaunchDisplayId(
                (v != null && v.getDisplay() != null) ? v.getDisplay().getDisplayId()
                        : Display.DEFAULT_DISPLAY);
        return activityOptions;
    }

+4 −0
Original line number Diff line number Diff line
@@ -182,6 +182,10 @@ public abstract class BaseDraggingActivity extends BaseActivity
        }
        ActivityOptions options =
                ActivityOptions.makeClipRevealAnimation(v, left, top, width, height);

        options.setLaunchDisplayId(
                (v != null && v.getDisplay() != null) ? v.getDisplay().getDisplayId()
                        : Display.DEFAULT_DISPLAY);
        RunnableList callback = new RunnableList();
        addOnResumeCallback(callback::executeAllAndDestroy);
        return new ActivityOptionsWrapper(options, callback);