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

Commit a18586cc authored by wilsonshih's avatar wilsonshih Committed by Wei Sheng Shih
Browse files

Fix missing check empty style splash screen when task switch.

Bug: 200771843
Test: show empty splash screen when launch a trampoline activity
from notification.
Change-Id: Ib167a3b66a8c4274a96faaa3ff4c2e902e929dab
parent 6d71d158
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) {