Merge "Desktop windowing wallpaper" into main
This commit is contained in:
commit
e993f92719
8 files changed
+61
-39
No files matched your search
@@ -88,8 +88,11 @@ public class LauncherSwipeHandlerV2 extends
|
||||
|
||||
final View workspaceView = findWorkspaceView(launchCookies,
|
||||
mRecentsView.getRunningTaskView());
|
||||
boolean canUseWorkspaceView = workspaceView != null && workspaceView.isAttachedToWindow()
|
||||
&& workspaceView.getHeight() > 0;
|
||||
boolean canUseWorkspaceView = workspaceView != null
|
||||
&& workspaceView.isAttachedToWindow()
|
||||
&& workspaceView.getHeight() > 0
|
||||
&& (mContainer.getDesktopVisibilityController() == null
|
||||
|| !mContainer.getDesktopVisibilityController().areDesktopTasksVisible());
|
||||
|
||||
mContainer.getRootView().setForceHideBackArrow(true);
|
||||
if (!TaskAnimationManager.ENABLE_SHELL_TRANSITIONS) {
|
||||
|
||||
@@ -222,8 +222,10 @@ public class RemoteTargetGluer {
|
||||
|
||||
for (int i = 0; i < mRemoteTargetHandles.length; i++) {
|
||||
RemoteAnimationTarget primaryTaskTarget = targets.apps[i];
|
||||
List<RemoteAnimationTarget> excludeTargets = Arrays.stream(targets.apps)
|
||||
.filter(target -> target.taskId != primaryTaskTarget.taskId).toList();
|
||||
mRemoteTargetHandles[i].mTransformParams.setTargetSet(
|
||||
createRemoteAnimationTargetsForTaskId(targets, primaryTaskTarget.taskId));
|
||||
createRemoteAnimationTargetsForTarget(targets, excludeTargets));
|
||||
mRemoteTargetHandles[i].mTaskViewSimulator.setPreview(primaryTaskTarget, null);
|
||||
}
|
||||
return mRemoteTargetHandles;
|
||||
@@ -289,33 +291,6 @@ public class RemoteTargetGluer {
|
||||
filteredApps, targets.wallpapers, targets.nonApps, targets.targetMode);
|
||||
}
|
||||
|
||||
/**
|
||||
* Ensures that we only animate one specific app target. Includes ancillary targets such as
|
||||
* home/recents
|
||||
*
|
||||
* @param targets remote animation targets to filter
|
||||
* @param taskId id for a task that we want this remote animation to apply to
|
||||
* @return {@link RemoteAnimationTargets} where app target only includes the app that has the
|
||||
* {@code taskId} that was passed in
|
||||
*/
|
||||
private RemoteAnimationTargets createRemoteAnimationTargetsForTaskId(
|
||||
RemoteAnimationTargets targets, int taskId) {
|
||||
RemoteAnimationTarget[] targetApp = null;
|
||||
for (RemoteAnimationTarget targetCompat : targets.unfilteredApps) {
|
||||
if (targetCompat.taskId == taskId) {
|
||||
targetApp = new RemoteAnimationTarget[]{targetCompat};
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (targetApp == null) {
|
||||
targetApp = new RemoteAnimationTarget[0];
|
||||
}
|
||||
|
||||
return new RemoteAnimationTargets(targetApp, targets.wallpapers, targets.nonApps,
|
||||
targets.targetMode);
|
||||
}
|
||||
|
||||
/**
|
||||
* The object returned by this is may be modified in
|
||||
* {@link #assignTargetsForSplitScreen(RemoteAnimationTargets)}, specifically the length of the
|
||||
|
||||
@@ -26,6 +26,7 @@ import static com.android.launcher3.LauncherState.OVERVIEW_MODAL_TASK;
|
||||
import static com.android.launcher3.LauncherState.OVERVIEW_SPLIT_SELECT;
|
||||
import static com.android.launcher3.LauncherState.SPRING_LOADED;
|
||||
import static com.android.launcher3.logging.StatsLogManager.LauncherEvent.LAUNCHER_SPLIT_SELECTION_EXIT_HOME;
|
||||
import static com.android.window.flags.Flags.enableDesktopWindowingWallpaperActivity;
|
||||
|
||||
import android.annotation.TargetApi;
|
||||
import android.content.Context;
|
||||
@@ -260,7 +261,8 @@ public class LauncherRecentsView extends RecentsView<QuickstepLauncher, Launcher
|
||||
super.onGestureAnimationStart(runningTasks, rotationTouchHelper);
|
||||
DesktopVisibilityController desktopVisibilityController =
|
||||
mContainer.getDesktopVisibilityController();
|
||||
if (desktopVisibilityController != null) {
|
||||
if (!enableDesktopWindowingWallpaperActivity() && desktopVisibilityController != null) {
|
||||
// TODO: b/333533253 - Remove after flag rollout
|
||||
desktopVisibilityController.setRecentsGestureStart();
|
||||
}
|
||||
}
|
||||
@@ -282,7 +284,8 @@ public class LauncherRecentsView extends RecentsView<QuickstepLauncher, Launcher
|
||||
}
|
||||
}
|
||||
super.onGestureAnimationEnd();
|
||||
if (desktopVisibilityController != null) {
|
||||
if (!enableDesktopWindowingWallpaperActivity() && desktopVisibilityController != null) {
|
||||
// TODO: b/333533253 - Remove after flag rollout
|
||||
desktopVisibilityController.setRecentsGestureEnd(endTarget);
|
||||
}
|
||||
if (showDesktopApps) {
|
||||
|
||||
Reference in new issue
Block a user