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

Commit 7bf1e9b7 authored by Wei Sheng Shih's avatar Wei Sheng Shih Committed by Android (Google) Code Review
Browse files

Merge "Fix missing check empty style splash screen when task switch." into sc-v2-dev

parents 8abc42e0 a18586cc
Loading
Loading
Loading
Loading
+4 −14
Original line number Diff line number Diff line
@@ -71,23 +71,13 @@ public class PhoneStartingWindowTypeAlgorithm implements StartingWindowTypeAlgor
                    + " topIsHome:" + topIsHome);
        }

        final int visibleSplashScreenType = legacySplashScreen
                ? STARTING_WINDOW_TYPE_LEGACY_SPLASH_SCREEN
                : STARTING_WINDOW_TYPE_SPLASH_SCREEN;

        if (!topIsHome) {
            if (!processRunning) {
            if (!processRunning || newTask || (taskSwitch && !activityCreated)) {
                return useEmptySplashScreen
                        ? STARTING_WINDOW_TYPE_EMPTY_SPLASH_SCREEN
                        : visibleSplashScreenType;
            }
            if (newTask) {
                return useEmptySplashScreen
                        ? STARTING_WINDOW_TYPE_EMPTY_SPLASH_SCREEN
                        : visibleSplashScreenType;
            }
            if (taskSwitch && !activityCreated) {
                return visibleSplashScreenType;
                        : legacySplashScreen
                                ? STARTING_WINDOW_TYPE_LEGACY_SPLASH_SCREEN
                                : STARTING_WINDOW_TYPE_SPLASH_SCREEN;
            }
        }
        if (taskSwitch && allowTaskSnapshot) {