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

Commit df7830bb authored by Android Build Coastguard Worker's avatar Android Build Coastguard Worker
Browse files

Snap for 9463735 from 2f4a1b99 to tm-qpr2-release

Change-Id: I32fcee8829d0fe318ba737c2b0cda203682ffc97
parents ce4df6a8 2f4a1b99
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -78,7 +78,7 @@
    <string name="allset_title" msgid="5021126669778966707">"Fertig!"</string>
    <string name="allset_hint" msgid="2384632994739392447">"Nach oben wischen, um den Startbildschirm aufzurufen"</string>
    <string name="allset_button_hint" msgid="2395219947744706291">"Startbildschirmtaste drücken, um zum Startbildschirm zu gehen"</string>
    <string name="allset_description_generic" msgid="5385500062202019855">"Du kannst dein Gerät (<xliff:g id="DEVICE">%1$s</xliff:g>) jetzt verwenden"</string>
    <string name="allset_description_generic" msgid="5385500062202019855">"Du kannst dein <xliff:g id="DEVICE">%1$s</xliff:g> jetzt verwenden"</string>
    <string name="default_device_name" msgid="6660656727127422487">"Gerät"</string>
    <string name="allset_navigation_settings" msgid="4713404605961476027"><annotation id="link">"Einstellungen der Systemsteuerung"</annotation></string>
    <string name="action_share" msgid="2648470652637092375">"Teilen"</string>
+17 −0
Original line number Diff line number Diff line
@@ -324,6 +324,9 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>,
    // May be set to false when mIsTransientTaskbar is true.
    private boolean mCanSlowSwipeGoHome = true;

    @Nullable
    private RemoteAnimationTargets.ReleaseCheck mSwipePipToHomeReleaseCheck = null;

    public AbsSwipeUpHandler(Context context, RecentsAnimationDeviceState deviceState,
            TaskAnimationManager taskAnimationManager, GestureState gestureState,
            long touchTimeMs, boolean continuingLastGesture,
@@ -869,6 +872,9 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>,
        mRemoteTargetHandles = mTargetGluer.assignTargetsForSplitScreen(mContext, targets);
        mRecentsAnimationController = controller;
        mRecentsAnimationTargets = targets;
        mSwipePipToHomeReleaseCheck = new RemoteAnimationTargets.ReleaseCheck();
        mSwipePipToHomeReleaseCheck.setCanRelease(true);
        mRecentsAnimationTargets.addReleaseCheck(mSwipePipToHomeReleaseCheck);

        // Only initialize the device profile, if it has not been initialized before, as in some
        // configurations targets.homeContentInsets may not be correct.
@@ -1430,9 +1436,16 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>,
                mSwipePipToHomeAnimator = createWindowAnimationToPip(
                        homeAnimFactory, runningTaskTarget, start);
                mSwipePipToHomeAnimators[0] = mSwipePipToHomeAnimator;
                if (mSwipePipToHomeReleaseCheck != null) {
                    mSwipePipToHomeReleaseCheck.setCanRelease(false);
                }
                windowAnim = mSwipePipToHomeAnimators;
            } else {
                mSwipePipToHomeAnimator = null;
                if (mSwipePipToHomeReleaseCheck != null) {
                    mSwipePipToHomeReleaseCheck.setCanRelease(true);
                    mSwipePipToHomeReleaseCheck = null;
                }
                windowAnim = createWindowAnimationToHome(start, homeAnimFactory);

                windowAnim[0].addAnimatorListener(new AnimationSuccessListener() {
@@ -1954,6 +1967,10 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>,
            finishRecentsControllerToHome(
                    () -> mStateCallback.setStateOnUiThread(STATE_CURRENT_TASK_FINISHED));
        }
        if (mSwipePipToHomeReleaseCheck != null) {
            mSwipePipToHomeReleaseCheck.setCanRelease(true);
            mSwipePipToHomeReleaseCheck = null;
        }
        doLogGesture(HOME, mRecentsView == null ? null : mRecentsView.getCurrentPageTaskView());
    }

+21 −8
Original line number Diff line number Diff line
@@ -262,6 +262,19 @@ public class TaplTestsQuickstep extends AbstractQuickStepTest {
        return launchedAppState;
    }

    private void quickSwitchToPreviousAppAndAssert(boolean toRight) {
        final LaunchedAppState launchedAppState = getAndAssertLaunchedApp();
        if (toRight) {
            launchedAppState.quickSwitchToPreviousApp();
        } else {
            launchedAppState.quickSwitchToPreviousAppSwipeLeft();
        }

        // While enable shell transition, Launcher can be resumed due to transient launch.
        waitForLauncherCondition("Launcher shouldn't stay in resume forever",
                this::isInLaunchedApp, 3000 /* timeout */);
    }

    @Test
    @PortraitLandscape
    public void testAllAppsFromHome() throws Exception {
@@ -288,13 +301,11 @@ public class TaplTestsQuickstep extends AbstractQuickStepTest {
        startTestActivity(3);
        startTestActivity(4);

        LaunchedAppState launchedAppState = getAndAssertLaunchedApp();
        launchedAppState.quickSwitchToPreviousApp();
        quickSwitchToPreviousAppAndAssert(true /* toRight */);
        assertTrue("The first app we should have quick switched to is not running",
                isTestActivityRunning(3));

        launchedAppState = getAndAssertLaunchedApp();
        launchedAppState.quickSwitchToPreviousApp();
        quickSwitchToPreviousAppAndAssert(true /* toRight */);
        if (mLauncher.getNavigationModel() == NavigationModel.THREE_BUTTON) {
            // 3-button mode toggles between 2 apps, rather than going back further.
            assertTrue("Second quick switch should have returned to the first app.",
@@ -303,12 +314,12 @@ public class TaplTestsQuickstep extends AbstractQuickStepTest {
            assertTrue("The second app we should have quick switched to is not running",
                    isTestActivityRunning(2));
        }
        launchedAppState = getAndAssertLaunchedApp();
        launchedAppState.quickSwitchToPreviousAppSwipeLeft();

        quickSwitchToPreviousAppAndAssert(false /* toRight */);
        assertTrue("The 2nd app we should have quick switched to is not running",
                isTestActivityRunning(3));

        launchedAppState = getAndAssertLaunchedApp();
        final LaunchedAppState launchedAppState = getAndAssertLaunchedApp();
        launchedAppState.switchToOverview();
    }

@@ -327,8 +338,10 @@ public class TaplTestsQuickstep extends AbstractQuickStepTest {
        launchedAppState.assertTaskbarHidden();

        // Quick-switch to the test app with swiping to right.
        launchedAppState.quickSwitchToPreviousApp();
        quickSwitchToPreviousAppAndAssert(true /* toRight */);

        assertTrue("The first app we should have quick switched to is not running",
                isTestActivityRunning(2));
        // Expect task bar visible when the launched app was the test activity.
        launchedAppState = getAndAssertLaunchedApp();
        launchedAppState.assertTaskbarVisible();
+14 −13
Original line number Diff line number Diff line
@@ -239,12 +239,12 @@ public class AlphabeticalAppsList<T extends Context & ActivityContext> implement
            mAdapterItems.addAll(mSearchResults);
        } else {
            int position = 0;
            boolean addApps = true;
            if (mWorkProviderManager != null) {
                position += mWorkProviderManager.addWorkItems(mAdapterItems);
                if (!mWorkProviderManager.shouldShowWorkApps()) {
                    return;
                }
                addApps = mWorkProviderManager.shouldShowWorkApps();
            }
            if (addApps) {
                String lastSectionName = null;
                for (AppInfo info : mApps) {
                    mAdapterItems.add(AdapterItem.asApp(info));
@@ -258,6 +258,7 @@ public class AlphabeticalAppsList<T extends Context & ActivityContext> implement
                    position++;
                }
            }
        }
        mAccessibilityResultsCount = (int) mAdapterItems.stream()
                .filter(AdapterItem::isCountedForAccessibility).count();

+2 −1
Original line number Diff line number Diff line
@@ -163,7 +163,8 @@ public abstract class BaseAllAppsContainerView<T extends Context & ActivityConte

        mWorkManager = new WorkProfileManager(
                mActivityContext.getSystemService(UserManager.class),
                this, LauncherPrefs.getPrefs(mActivityContext));
                this, LauncherPrefs.getPrefs(mActivityContext),
                mActivityContext.getStatsLogManager());
        mAH = Arrays.asList(null, null, null);
        mNavBarScrimPaint = new Paint();
        mNavBarScrimPaint.setColor(Themes.getAttrColor(context, R.attr.allAppsNavBarScrimColor));
Loading