7/ Rename RecentsAnimationWrapper

- Move the recents animation classes out of util into base quickstep pkg
- Clean up some local var names

Bug: 141886704
Change-Id: I1556179e203cbb43b77ea58e6fe520aa9944099b
This commit is contained in:
Winson Chung 2019-10-02 17:29:58 -07:00
parent 9e876a34ee
commit d3da92ac66
34 changed files with 157 additions and 144 deletions

View File

@ -32,7 +32,6 @@ import android.util.Log;
import com.android.launcher3.BaseDraggingActivity;
import com.android.launcher3.LauncherAnimationRunner;
import com.android.quickstep.util.RemoteAnimationProvider;
import com.android.quickstep.util.RemoteAnimationTargets;
import com.android.quickstep.views.IconRecentsView;
import com.android.systemui.shared.system.ActivityOptionsCompat;
import com.android.systemui.shared.system.RemoteAnimationAdapterCompat;
@ -113,9 +112,9 @@ final class AppToOverviewAnimationProvider<T extends BaseDraggingActivity> imple
return anim;
}
RemoteAnimationTargets targetSet =
RemoteAnimationTargets targets =
new RemoteAnimationTargets(appTargets, wallpaperTargets, MODE_CLOSING);
mRecentsView.setTransitionedFromApp(!targetSet.isAnimatingHome());
mRecentsView.setTransitionedFromApp(!targets.isAnimatingHome());
RemoteAnimationTargetCompat recentsTarget = null;
RemoteAnimationTargetCompat closingAppTarget = null;

View File

@ -27,7 +27,6 @@ import androidx.annotation.Nullable;
import com.android.launcher3.anim.AnimatorPlaybackController;
import com.android.launcher3.userevent.nano.LauncherLogProto;
import com.android.quickstep.util.ActivityInitListener;
import com.android.quickstep.util.RemoteAnimationTargets;
import com.android.quickstep.views.IconRecentsView;
import java.util.function.BiPredicate;

View File

@ -40,26 +40,28 @@ import com.android.systemui.shared.system.LatencyTrackerCompat;
public class OverviewCommandHelper {
private final Context mContext;
private final ActivityManagerWrapper mAM;
private final RecentsAnimationDeviceState mDeviceState;
private final RecentsModel mRecentsModel;
private final OverviewComponentObserver mOverviewComponentObserver;
private long mLastToggleTime;
public OverviewCommandHelper(Context context, OverviewComponentObserver observer) {
public OverviewCommandHelper(Context context, RecentsAnimationDeviceState deviceState,
OverviewComponentObserver observer) {
mContext = context;
mAM = ActivityManagerWrapper.getInstance();
mDeviceState = deviceState;
mRecentsModel = RecentsModel.INSTANCE.get(mContext);
mOverviewComponentObserver = observer;
}
public void onOverviewToggle() {
// If currently screen pinning, do not enter overview
if (mAM.isScreenPinningActive()) {
if (mDeviceState.isScreenPinningActive()) {
return;
}
mAM.closeSystemWindows(CLOSE_SYSTEM_WINDOWS_REASON_RECENTS);
ActivityManagerWrapper.getInstance()
.closeSystemWindows(CLOSE_SYSTEM_WINDOWS_REASON_RECENTS);
MAIN_EXECUTOR.execute(new RecentsActivityCommand<>());
}

View File

@ -148,7 +148,7 @@ public class TouchInteractionService extends Service {
public void onUserUnlocked() {
mRecentsModel = RecentsModel.INSTANCE.get(this);
mOverviewComponentObserver = new OverviewComponentObserver(this, mDeviceState);
mOverviewCommandHelper = new OverviewCommandHelper(this,
mOverviewCommandHelper = new OverviewCommandHelper(this, mDeviceState,
mOverviewComponentObserver);
}

View File

@ -32,7 +32,6 @@ import com.android.launcher3.BaseDraggingActivity;
import com.android.launcher3.anim.AnimationSuccessListener;
import com.android.quickstep.util.AppWindowAnimationHelper;
import com.android.quickstep.util.RemoteAnimationProvider;
import com.android.quickstep.util.RemoteAnimationTargets;
import com.android.quickstep.views.RecentsView;
import com.android.systemui.shared.system.RemoteAnimationTargetCompat;
import com.android.systemui.shared.system.SyncRtSurfaceTransactionApplierCompat;
@ -115,11 +114,11 @@ final class AppToOverviewAnimationProvider<T extends BaseDraggingActivity> imple
return anim;
}
RemoteAnimationTargets targetSet = new RemoteAnimationTargets(appTargets,
RemoteAnimationTargets targets = new RemoteAnimationTargets(appTargets,
wallpaperTargets, MODE_CLOSING);
// Use the top closing app to determine the insets for the animation
RemoteAnimationTargetCompat runningTaskTarget = targetSet.findTask(mTargetTaskId);
RemoteAnimationTargetCompat runningTaskTarget = targets.findTask(mTargetTaskId);
if (runningTaskTarget == null) {
Log.e(TAG, "No closing app");
anim.play(ValueAnimator.ofInt(0, 1).setDuration(RECENTS_LAUNCH_DURATION));
@ -149,12 +148,12 @@ final class AppToOverviewAnimationProvider<T extends BaseDraggingActivity> imple
valueAnimator.setInterpolator(TOUCH_RESPONSE_INTERPOLATOR);
valueAnimator.addUpdateListener((v) -> {
params.setProgress((float) v.getAnimatedValue())
.setTargetSet(targetSet)
.setTargetSet(targets)
.setLauncherOnTop(true);
clipHelper.applyTransform(params);
});
if (targetSet.isAnimatingHome()) {
if (targets.isAnimatingHome()) {
// If we are animating home, fade in the opening targets
RemoteAnimationTargets openingSet = new RemoteAnimationTargets(appTargets,
wallpaperTargets, MODE_OPENING);

View File

@ -58,14 +58,12 @@ import com.android.launcher3.graphics.RotationMode;
import com.android.launcher3.views.FloatingIconView;
import com.android.quickstep.ActivityControlHelper.HomeAnimationFactory;
import com.android.quickstep.SysUINavigationMode.Mode;
import com.android.quickstep.inputconsumers.InputConsumer;
import com.android.quickstep.util.ActiveGestureLog;
import com.android.quickstep.util.ActivityInitListener;
import com.android.quickstep.util.AppWindowAnimationHelper;
import com.android.quickstep.util.AppWindowAnimationHelper.TransformParams;
import com.android.quickstep.util.RectFSpringAnim;
import com.android.quickstep.util.RecentsAnimationTargets;
import com.android.quickstep.util.RecentsAnimationCallbacks.RecentsAnimationListener;
import com.android.quickstep.RecentsAnimationCallbacks.RecentsAnimationListener;
import com.android.quickstep.views.RecentsView;
import com.android.quickstep.views.TaskView;
import com.android.systemui.shared.recents.model.ThumbnailData;
@ -118,7 +116,7 @@ public abstract class BaseSwipeUpHandler<T extends BaseDraggingActivity, Q exten
protected final ActivityInitListener mActivityInitListener;
protected final InputConsumerController mInputConsumer;
protected RecentsAnimationWrapper mRecentsAnimationWrapper;
protected RecentsAnimationController mRecentsAnimationController;
protected RecentsAnimationTargets mRecentsAnimationTargets;
// Callbacks to be made once the recents animation starts
@ -227,7 +225,7 @@ public abstract class BaseSwipeUpHandler<T extends BaseDraggingActivity, Q exten
});
mRecentsView.setAppWindowAnimationHelper(mAppWindowAnimationHelper);
runOnRecentsAnimationStart(() ->
mRecentsView.setRecentsAnimationTargets(mRecentsAnimationWrapper,
mRecentsView.setRecentsAnimationTargets(mRecentsAnimationController,
mRecentsAnimationTargets));
}
@ -240,7 +238,7 @@ public abstract class BaseSwipeUpHandler<T extends BaseDraggingActivity, Q exten
} else {
int taskId = mRecentsView.getNextPageTaskView().getTask().key.id;
mFinishingRecentsAnimationForNewTaskId = taskId;
mRecentsAnimationWrapper.finish(true /* toRecents */, () -> {
mRecentsAnimationController.finish(true /* toRecents */, () -> {
if (!mCanceled) {
TaskView nextTask = mRecentsView.getTaskView(taskId);
if (nextTask != null) {
@ -284,17 +282,17 @@ public abstract class BaseSwipeUpHandler<T extends BaseDraggingActivity, Q exten
}
@Override
public void onRecentsAnimationStart(RecentsAnimationWrapper recentsAnimationController,
RecentsAnimationTargets targetSet) {
mRecentsAnimationWrapper = recentsAnimationController;
mRecentsAnimationTargets = targetSet;
public void onRecentsAnimationStart(RecentsAnimationController recentsAnimationController,
RecentsAnimationTargets targets) {
mRecentsAnimationController = recentsAnimationController;
mRecentsAnimationTargets = targets;
DeviceProfile dp = InvariantDeviceProfile.INSTANCE.get(mContext).getDeviceProfile(mContext);
final Rect overviewStackBounds;
RemoteAnimationTargetCompat runningTaskTarget = targetSet.findTask(mRunningTaskId);
RemoteAnimationTargetCompat runningTaskTarget = targets.findTask(mRunningTaskId);
if (targetSet.minimizedHomeBounds != null && runningTaskTarget != null) {
if (targets.minimizedHomeBounds != null && runningTaskTarget != null) {
overviewStackBounds = mActivityControlHelper
.getOverviewWindowBounds(targetSet.minimizedHomeBounds, runningTaskTarget);
.getOverviewWindowBounds(targets.minimizedHomeBounds, runningTaskTarget);
dp = dp.getMultiWindowProfile(mContext, new Point(
overviewStackBounds.width(), overviewStackBounds.height()));
} else {
@ -302,7 +300,7 @@ public abstract class BaseSwipeUpHandler<T extends BaseDraggingActivity, Q exten
dp = dp.copy(mContext);
overviewStackBounds = getStackBounds(dp);
}
dp.updateInsets(targetSet.homeContentInsets);
dp.updateInsets(targets.homeContentInsets);
dp.updateIsSeascape(mContext);
if (runningTaskTarget != null) {
mAppWindowAnimationHelper.updateSource(overviewStackBounds, runningTaskTarget);
@ -322,13 +320,13 @@ public abstract class BaseSwipeUpHandler<T extends BaseDraggingActivity, Q exten
@Override
public void onRecentsAnimationCanceled(ThumbnailData thumbnailData) {
mRecentsAnimationWrapper = null;
mRecentsAnimationController = null;
mRecentsAnimationTargets = null;
}
@Override
public void onRecentsAnimationFinished(RecentsAnimationWrapper controller) {
mRecentsAnimationWrapper = null;
public void onRecentsAnimationFinished(RecentsAnimationController controller) {
mRecentsAnimationController = null;
mRecentsAnimationTargets = null;
}

View File

@ -37,7 +37,6 @@ import com.android.launcher3.userevent.nano.LauncherLogProto;
import com.android.quickstep.fallback.FallbackRecentsView;
import com.android.quickstep.util.ActivityInitListener;
import com.android.quickstep.util.LayoutUtils;
import com.android.quickstep.util.RemoteAnimationTargets;
import com.android.quickstep.views.RecentsView;
import com.android.systemui.shared.system.RemoteAnimationTargetCompat;

View File

@ -27,6 +27,7 @@ import android.os.Build;
import android.os.SystemClock;
import android.view.ViewConfiguration;
import androidx.annotation.BinderThread;
import com.android.launcher3.BaseDraggingActivity;
import com.android.launcher3.logging.UserEventDispatcher;
import com.android.launcher3.userevent.nano.LauncherLogProto;
@ -44,37 +45,43 @@ import com.android.systemui.shared.system.RemoteAnimationTargetCompat;
public class OverviewCommandHelper {
private final Context mContext;
private final ActivityManagerWrapper mAM;
private final RecentsAnimationDeviceState mDeviceState;
private final RecentsModel mRecentsModel;
private final OverviewComponentObserver mOverviewComponentObserver;
private long mLastToggleTime;
public OverviewCommandHelper(Context context, OverviewComponentObserver observer) {
public OverviewCommandHelper(Context context, RecentsAnimationDeviceState deviceState,
OverviewComponentObserver observer) {
mContext = context;
mAM = ActivityManagerWrapper.getInstance();
mDeviceState = deviceState;
mRecentsModel = RecentsModel.INSTANCE.get(mContext);
mOverviewComponentObserver = observer;
}
@BinderThread
public void onOverviewToggle() {
// If currently screen pinning, do not enter overview
if (mAM.isScreenPinningActive()) {
if (mDeviceState.isScreenPinningActive()) {
return;
}
mAM.closeSystemWindows(CLOSE_SYSTEM_WINDOWS_REASON_RECENTS);
ActivityManagerWrapper.getInstance()
.closeSystemWindows(CLOSE_SYSTEM_WINDOWS_REASON_RECENTS);
MAIN_EXECUTOR.execute(new RecentsActivityCommand<>());
}
@BinderThread
public void onOverviewShown(boolean triggeredFromAltTab) {
MAIN_EXECUTOR.execute(new ShowRecentsCommand(triggeredFromAltTab));
}
@BinderThread
public void onOverviewHidden() {
MAIN_EXECUTOR.execute(new HideRecentsCommand());
}
@BinderThread
public void onTip(int actionType, int viewType) {
MAIN_EXECUTOR.execute(() ->
UserEventDispatcher.newInstance(mContext).logActionTip(actionType, viewType));

View File

@ -22,9 +22,7 @@ import android.util.Log;
import com.android.launcher3.Utilities;
import com.android.launcher3.config.FeatureFlags;
import com.android.launcher3.util.Preconditions;
import com.android.quickstep.util.RecentsAnimationCallbacks;
import com.android.quickstep.util.RecentsAnimationTargets;
import com.android.quickstep.util.RecentsAnimationCallbacks.RecentsAnimationListener;
import com.android.quickstep.RecentsAnimationCallbacks.RecentsAnimationListener;
import com.android.systemui.shared.recents.model.ThumbnailData;
@ -38,7 +36,7 @@ public class SwipeSharedState implements RecentsAnimationListener {
private OverviewComponentObserver mOverviewComponentObserver;
private RecentsAnimationCallbacks mRecentsAnimationListener;
private RecentsAnimationWrapper mLastRecentsAnimationController;
private RecentsAnimationController mLastRecentsAnimationController;
private RecentsAnimationTargets mLastAnimationTarget;
private boolean mLastAnimationCancelled = false;
@ -55,10 +53,10 @@ public class SwipeSharedState implements RecentsAnimationListener {
}
@Override
public final void onRecentsAnimationStart(RecentsAnimationWrapper controller,
RecentsAnimationTargets targetSet) {
public final void onRecentsAnimationStart(RecentsAnimationController controller,
RecentsAnimationTargets targets) {
mLastRecentsAnimationController = controller;
mLastAnimationTarget = targetSet;
mLastAnimationTarget = targets;
mLastAnimationCancelled = false;
mLastAnimationRunning = true;
@ -78,7 +76,7 @@ public class SwipeSharedState implements RecentsAnimationListener {
}
@Override
public final void onRecentsAnimationFinished(RecentsAnimationWrapper controller) {
public final void onRecentsAnimationFinished(RecentsAnimationController controller) {
if (mLastRecentsAnimationController == controller) {
mLastAnimationRunning = false;
}
@ -117,7 +115,7 @@ public class SwipeSharedState implements RecentsAnimationListener {
mLastAnimationRunning = false;
}
public RecentsAnimationCallbacks newRecentsAnimationListenerSet() {
public RecentsAnimationCallbacks newRecentsAnimationCallbacks() {
Preconditions.assertUIThread();
if (mLastAnimationRunning) {

View File

@ -33,7 +33,6 @@ import com.android.launcher3.ItemInfo;
import com.android.launcher3.Utilities;
import com.android.quickstep.util.AppWindowAnimationHelper;
import com.android.quickstep.util.MultiValueUpdateListener;
import com.android.quickstep.util.RemoteAnimationTargets;
import com.android.quickstep.views.RecentsView;
import com.android.quickstep.views.TaskView;
import com.android.systemui.shared.recents.model.Task;
@ -121,13 +120,13 @@ public final class TaskViewUtils {
RemoteAnimationTargetCompat[] wallpaperTargets, final AppWindowAnimationHelper inOutHelper) {
SyncRtSurfaceTransactionApplierCompat applier =
new SyncRtSurfaceTransactionApplierCompat(v);
final RemoteAnimationTargets targetSet =
final RemoteAnimationTargets targets =
new RemoteAnimationTargets(appTargets, wallpaperTargets, MODE_OPENING);
targetSet.addDependentTransactionApplier(applier);
targets.addDependentTransactionApplier(applier);
AppWindowAnimationHelper.TransformParams params =
new AppWindowAnimationHelper.TransformParams()
.setSyncTransactionApplier(applier)
.setTargetSet(targetSet)
.setTargetSet(targets)
.setLauncherOnTop(true);
final RecentsView recentsView = v.getRecentsView();
@ -149,7 +148,7 @@ public final class TaskViewUtils {
BaseActivity.fromContext(v.getContext()).getDeviceProfile(),
true /* isOpening */);
inOutHelper.fromTaskThumbnailView(v.getThumbnail(), (RecentsView) v.getParent(),
targetSet.apps.length == 0 ? null : targetSet.apps[0]);
targets.apps.length == 0 ? null : targets.apps[0]);
mThumbnailRect = new RectF(inOutHelper.getTargetRect());
mThumbnailRect.offset(-v.getTranslationX(), -v.getTranslationY());
@ -203,7 +202,7 @@ public final class TaskViewUtils {
appAnimator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
targetSet.release();
targets.release();
}
});
return appAnimator;

View File

@ -48,6 +48,7 @@ import android.view.Choreographer;
import android.view.InputEvent;
import android.view.MotionEvent;
import androidx.annotation.BinderThread;
import androidx.annotation.UiThread;
import androidx.annotation.WorkerThread;
@ -66,7 +67,6 @@ import com.android.quickstep.inputconsumers.AccessibilityInputConsumer;
import com.android.quickstep.inputconsumers.AssistantInputConsumer;
import com.android.quickstep.inputconsumers.DeviceLockedInputConsumer;
import com.android.quickstep.inputconsumers.FallbackNoButtonInputConsumer;
import com.android.quickstep.inputconsumers.InputConsumer;
import com.android.quickstep.inputconsumers.OtherActivityInputConsumer;
import com.android.quickstep.inputconsumers.OverviewInputConsumer;
import com.android.quickstep.inputconsumers.OverviewWithoutFocusInputConsumer;
@ -123,6 +123,7 @@ public class TouchInteractionService extends Service implements
private final IBinder mMyBinder = new IOverviewProxy.Stub() {
@BinderThread
public void onInitialize(Bundle bundle) {
ISystemUiProxy proxy = ISystemUiProxy.Stub.asInterface(
bundle.getBinder(KEY_EXTRA_SYSUI_PROXY));
@ -133,16 +134,19 @@ public class TouchInteractionService extends Service implements
sIsInitialized = true;
}
@BinderThread
@Override
public void onOverviewToggle() {
mOverviewCommandHelper.onOverviewToggle();
}
@BinderThread
@Override
public void onOverviewShown(boolean triggeredFromAltTab) {
mOverviewCommandHelper.onOverviewShown(triggeredFromAltTab);
}
@BinderThread
@Override
public void onOverviewHidden(boolean triggeredFromAltTab, boolean triggeredFromHomeKey) {
if (triggeredFromAltTab && !triggeredFromHomeKey) {
@ -151,23 +155,27 @@ public class TouchInteractionService extends Service implements
}
}
@BinderThread
@Override
public void onTip(int actionType, int viewType) {
mOverviewCommandHelper.onTip(actionType, viewType);
}
@BinderThread
@Override
public void onAssistantAvailable(boolean available) {
MAIN_EXECUTOR.execute(() -> mDeviceState.setAssistantAvailable(available));
MAIN_EXECUTOR.execute(TouchInteractionService.this::onAssistantVisibilityChanged);
}
@BinderThread
@Override
public void onAssistantVisibilityChanged(float visibility) {
MAIN_EXECUTOR.execute(() -> mDeviceState.setAssistantVisibility(visibility));
MAIN_EXECUTOR.execute(TouchInteractionService.this::onAssistantVisibilityChanged);
}
@BinderThread
public void onBackAction(boolean completed, int downX, int downY, boolean isButton,
boolean gestureSwipeLeft) {
if (mOverviewComponentObserver == null) {
@ -184,11 +192,13 @@ public class TouchInteractionService extends Service implements
}
}
@BinderThread
public void onSystemUiStateChanged(int stateFlags) {
MAIN_EXECUTOR.execute(() -> mDeviceState.setSystemUiFlags(stateFlags));
MAIN_EXECUTOR.execute(TouchInteractionService.this::onSystemUiFlagsChanged);
}
@BinderThread
public void onActiveNavBarRegionChanges(Region region) {
MAIN_EXECUTOR.execute(() -> mDeviceState.setDeferredGestureRegion(region));
}
@ -314,10 +324,12 @@ public class TouchInteractionService extends Service implements
resetHomeBounceSeenOnQuickstepEnabledFirstTime();
}
@UiThread
public void onUserUnlocked() {
mRecentsModel = RecentsModel.INSTANCE.get(this);
mOverviewComponentObserver = new OverviewComponentObserver(this, mDeviceState);
mOverviewCommandHelper = new OverviewCommandHelper(this, mOverviewComponentObserver);
mOverviewCommandHelper = new OverviewCommandHelper(this, mDeviceState,
mOverviewComponentObserver);
mInputConsumer = InputConsumerController.getRecentsAnimationInputConsumer();
sSwipeSharedState.setOverviewComponentObserver(mOverviewComponentObserver);

View File

@ -75,12 +75,10 @@ import com.android.quickstep.ActivityControlHelper.AnimationFactory;
import com.android.quickstep.ActivityControlHelper.AnimationFactory.ShelfAnimState;
import com.android.quickstep.ActivityControlHelper.HomeAnimationFactory;
import com.android.quickstep.SysUINavigationMode.Mode;
import com.android.quickstep.inputconsumers.InputConsumer;
import com.android.quickstep.inputconsumers.OverviewInputConsumer;
import com.android.quickstep.util.ActiveGestureLog;
import com.android.quickstep.util.AppWindowAnimationHelper.TargetAlphaProvider;
import com.android.quickstep.util.RectFSpringAnim;
import com.android.quickstep.util.RecentsAnimationTargets;
import com.android.quickstep.views.LiveTileOverlay;
import com.android.quickstep.views.RecentsView;
import com.android.quickstep.views.TaskView;
@ -594,8 +592,8 @@ public class WindowTransformSwipeHandler<T extends BaseDraggingActivity>
: centermostTask.getThumbnail().getSysUiStatusNavFlags();
boolean useHomeScreenFlags = windowProgress > 1 - UPDATE_SYSUI_FLAGS_THRESHOLD;
// We will handle the sysui flags based on the centermost task view.
if (mRecentsAnimationWrapper != null) {
mRecentsAnimationWrapper.setWindowThresholdCrossed(centermostTaskFlags != 0
if (mRecentsAnimationController != null) {
mRecentsAnimationController.setWindowThresholdCrossed(centermostTaskFlags != 0
|| useHomeScreenFlags);
}
int sysuiFlags = useHomeScreenFlags ? 0 : centermostTaskFlags;
@ -604,14 +602,14 @@ public class WindowTransformSwipeHandler<T extends BaseDraggingActivity>
}
@Override
public void onRecentsAnimationStart(RecentsAnimationWrapper controller,
RecentsAnimationTargets targetSet) {
ActiveGestureLog.INSTANCE.addLog("startRecentsAnimationCallback", targetSet.apps.length);
super.onRecentsAnimationStart(controller, targetSet);
public void onRecentsAnimationStart(RecentsAnimationController controller,
RecentsAnimationTargets targets) {
ActiveGestureLog.INSTANCE.addLog("startRecentsAnimationCallback", targets.apps.length);
super.onRecentsAnimationStart(controller, targets);
// Only add the callback to enable the input consumer after we actually have the controller
mStateCallback.addCallback(STATE_APP_CONTROLLER_RECEIVED | STATE_GESTURE_STARTED,
mRecentsAnimationWrapper::enableInputConsumer);
mRecentsAnimationController::enableInputConsumer);
setStateOnUiThread(STATE_APP_CONTROLLER_RECEIVED);
mPassedOverviewThreshold = false;
@ -813,8 +811,8 @@ public class WindowTransformSwipeHandler<T extends BaseDraggingActivity>
}
}
if (endTarget.isLauncher && mRecentsAnimationWrapper != null) {
mRecentsAnimationWrapper.enableInputProxy(mInputConsumer,
if (endTarget.isLauncher && mRecentsAnimationController != null) {
mRecentsAnimationController.enableInputProxy(mInputConsumer,
this::createNewInputProxyHandler);
}
@ -1022,7 +1020,7 @@ public class WindowTransformSwipeHandler<T extends BaseDraggingActivity>
@UiThread
private void resumeLastTask() {
mRecentsAnimationWrapper.finish(false /* toRecents */, null);
mRecentsAnimationController.finish(false /* toRecents */, null);
ActiveGestureLog.INSTANCE.addLog("finishRecentsAnimation", false);
doLogGesture(LAST_TASK);
reset();
@ -1113,10 +1111,10 @@ public class WindowTransformSwipeHandler<T extends BaseDraggingActivity>
private void switchToScreenshot() {
if (ENABLE_QUICKSTEP_LIVE_TILE.get()) {
if (mRecentsAnimationWrapper != null) {
if (mRecentsAnimationController != null) {
// Update the screenshot of the task
if (mTaskSnapshot == null) {
mTaskSnapshot = mRecentsAnimationWrapper.screenshotTask(mRunningTaskId);
mTaskSnapshot = mRecentsAnimationController.screenshotTask(mRunningTaskId);
}
mRecentsView.updateThumbnail(mRunningTaskId, mTaskSnapshot, false /* refreshNow */);
}
@ -1126,10 +1124,10 @@ public class WindowTransformSwipeHandler<T extends BaseDraggingActivity>
setStateOnUiThread(STATE_SCREENSHOT_CAPTURED);
} else {
boolean finishTransitionPosted = false;
if (mRecentsAnimationWrapper != null) {
if (mRecentsAnimationController != null) {
// Update the screenshot of the task
if (mTaskSnapshot == null) {
mTaskSnapshot = mRecentsAnimationWrapper.screenshotTask(mRunningTaskId);
mTaskSnapshot = mRecentsAnimationController.screenshotTask(mRunningTaskId);
}
final TaskView taskView;
if (mGestureEndTarget == HOME) {
@ -1162,8 +1160,8 @@ public class WindowTransformSwipeHandler<T extends BaseDraggingActivity>
// If there are no targets, then there is nothing to finish
setStateOnUiThread(STATE_CURRENT_TASK_FINISHED);
} else {
synchronized (mRecentsAnimationWrapper) {
mRecentsAnimationWrapper.finish(true /* toRecents */,
synchronized (mRecentsAnimationController) {
mRecentsAnimationController.finish(true /* toRecents */,
() -> setStateOnUiThread(STATE_CURRENT_TASK_FINISHED));
}
}
@ -1171,8 +1169,8 @@ public class WindowTransformSwipeHandler<T extends BaseDraggingActivity>
}
private void finishCurrentTransitionToHome() {
synchronized (mRecentsAnimationWrapper) {
mRecentsAnimationWrapper.finish(true /* toRecents */,
synchronized (mRecentsAnimationController) {
mRecentsAnimationController.finish(true /* toRecents */,
() -> setStateOnUiThread(STATE_CURRENT_TASK_FINISHED),
true /* sendUserLeaveHint */);
}
@ -1183,8 +1181,8 @@ public class WindowTransformSwipeHandler<T extends BaseDraggingActivity>
private void setupLauncherUiAfterSwipeUpToRecentsAnimation() {
endLauncherTransitionController();
mActivityControlHelper.onSwipeUpToRecentsComplete(mActivity);
if (mRecentsAnimationWrapper != null) {
mRecentsAnimationWrapper.setDeferCancelUntilNextTransition(true /* defer */,
if (mRecentsAnimationController != null) {
mRecentsAnimationController.setDeferCancelUntilNextTransition(true /* defer */,
true /* screenshot */);
}
mRecentsView.onSwipeUpAnimationSuccess();

View File

@ -29,6 +29,7 @@ import android.view.VelocityTracker;
import android.view.ViewConfiguration;
import com.android.launcher3.R;
import com.android.quickstep.InputConsumer;
import com.android.quickstep.RecentsAnimationDeviceState;
import com.android.quickstep.util.MotionPauseDetector;
import com.android.quickstep.SystemUiProxy;

View File

@ -49,6 +49,7 @@ import com.android.launcher3.R;
import com.android.launcher3.anim.Interpolators;
import com.android.launcher3.logging.UserEventDispatcher;
import com.android.quickstep.ActivityControlHelper;
import com.android.quickstep.InputConsumer;
import com.android.quickstep.SystemUiProxy;
import com.android.systemui.shared.system.InputMonitorCompat;

View File

@ -2,6 +2,7 @@ package com.android.quickstep.inputconsumers;
import android.view.MotionEvent;
import com.android.quickstep.InputConsumer;
import com.android.systemui.shared.system.InputMonitorCompat;
public abstract class DelegateInputConsumer implements InputConsumer {

View File

@ -39,15 +39,15 @@ import android.view.ViewConfiguration;
import com.android.launcher3.R;
import com.android.launcher3.Utilities;
import com.android.launcher3.util.DefaultDisplay;
import com.android.quickstep.InputConsumer;
import com.android.quickstep.LockScreenRecentsActivity;
import com.android.quickstep.MultiStateCallback;
import com.android.quickstep.RecentsAnimationController;
import com.android.quickstep.RecentsAnimationDeviceState;
import com.android.quickstep.RecentsAnimationWrapper;
import com.android.quickstep.SwipeSharedState;
import com.android.quickstep.RecentsAnimationCallbacks;
import com.android.quickstep.RecentsAnimationTargets;
import com.android.quickstep.util.AppWindowAnimationHelper;
import com.android.quickstep.util.RecentsAnimationCallbacks;
import com.android.quickstep.util.RecentsAnimationTargets;
import com.android.systemui.shared.recents.model.ThumbnailData;
import com.android.systemui.shared.system.InputMonitorCompat;
import com.android.systemui.shared.system.RemoteAnimationTargetCompat;
@ -92,7 +92,7 @@ public class DeviceLockedInputConsumer implements InputConsumer,
private boolean mThresholdCrossed = false;
private RecentsAnimationWrapper mRecentsAnimationController;
private RecentsAnimationController mRecentsAnimationController;
private RecentsAnimationTargets mRecentsAnimationTargets;
public DeviceLockedInputConsumer(Context context, RecentsAnimationDeviceState deviceState,
@ -204,9 +204,8 @@ public class DeviceLockedInputConsumer implements InputConsumer,
private void startRecentsTransition() {
mThresholdCrossed = true;
RecentsAnimationCallbacks newListenerSet =
mSwipeSharedState.newRecentsAnimationListenerSet();
newListenerSet.addListener(this);
RecentsAnimationCallbacks callbacks = mSwipeSharedState.newRecentsAnimationCallbacks();
callbacks.addListener(this);
Intent intent = new Intent(Intent.ACTION_MAIN)
.addCategory(Intent.CATEGORY_DEFAULT)
.setComponent(new ComponentName(mContext, LockScreenRecentsActivity.class))
@ -214,17 +213,17 @@ public class DeviceLockedInputConsumer implements InputConsumer,
.putExtra(INTENT_EXTRA_LOG_TRACE_ID, mLogId);
mInputMonitorCompat.pilferPointers();
startRecentsActivityAsync(intent, newListenerSet);
startRecentsActivityAsync(intent, callbacks);
}
@Override
public void onRecentsAnimationStart(RecentsAnimationWrapper controller,
RecentsAnimationTargets targetSet) {
public void onRecentsAnimationStart(RecentsAnimationController controller,
RecentsAnimationTargets targets) {
mRecentsAnimationController = controller;
mRecentsAnimationTargets = targetSet;
mRecentsAnimationTargets = targets;
Rect displaySize = new Rect(0, 0, mDisplaySize.x, mDisplaySize.y);
RemoteAnimationTargetCompat targetCompat = targetSet.findTask(mRunningTaskId);
RemoteAnimationTargetCompat targetCompat = targets.findTask(mRunningTaskId);
if (targetCompat != null) {
mAppWindowAnimationHelper.updateSource(displaySize, targetCompat);
}

View File

@ -42,15 +42,16 @@ import com.android.launcher3.util.ObjectWrapper;
import com.android.quickstep.ActivityControlHelper.HomeAnimationFactory;
import com.android.quickstep.AnimatedFloat;
import com.android.quickstep.BaseSwipeUpHandler;
import com.android.quickstep.InputConsumer;
import com.android.quickstep.MultiStateCallback;
import com.android.quickstep.OverviewComponentObserver;
import com.android.quickstep.RecentsActivity;
import com.android.quickstep.RecentsAnimationWrapper;
import com.android.quickstep.RecentsAnimationController;
import com.android.quickstep.RecentsModel;
import com.android.quickstep.SwipeSharedState;
import com.android.quickstep.fallback.FallbackRecentsView;
import com.android.quickstep.util.RectFSpringAnim;
import com.android.quickstep.util.RecentsAnimationTargets;
import com.android.quickstep.RecentsAnimationTargets;
import com.android.quickstep.views.TaskView;
import com.android.systemui.shared.recents.model.ThumbnailData;
import com.android.systemui.shared.system.ActivityManagerWrapper;
@ -232,8 +233,8 @@ public class FallbackNoButtonInputConsumer extends
@Override
public void updateFinalShift() {
mTransformParams.setProgress(mCurrentShift.value);
if (mRecentsAnimationWrapper != null) {
mRecentsAnimationWrapper.setWindowThresholdCrossed(!mInQuickSwitchMode
if (mRecentsAnimationController != null) {
mRecentsAnimationController.setWindowThresholdCrossed(!mInQuickSwitchMode
&& (mCurrentShift.value > 1 - UPDATE_SYSUI_FLAGS_THRESHOLD));
}
if (mRecentsAnimationTargets != null) {
@ -319,25 +320,25 @@ public class FallbackNoButtonInputConsumer extends
switch (mEndTarget) {
case HOME: {
if (mSwipeUpOverHome) {
mRecentsAnimationWrapper.finish(false, null, false);
mRecentsAnimationController.finish(false, null, false);
// Send a home intent to clear the task stack
mContext.startActivity(mOverviewComponentObserver.getHomeIntent());
} else {
mRecentsAnimationWrapper.finish(true, null, true);
mRecentsAnimationController.finish(true, null, true);
}
break;
}
case LAST_TASK:
mRecentsAnimationWrapper.finish(false, null, false);
mRecentsAnimationController.finish(false, null, false);
break;
case RECENTS: {
if (mSwipeUpOverHome) {
mRecentsAnimationWrapper.finish(true, null, true);
mRecentsAnimationController.finish(true, null, true);
break;
}
ThumbnailData thumbnail = mRecentsAnimationWrapper.screenshotTask(mRunningTaskId);
mRecentsAnimationWrapper.setDeferCancelUntilNextTransition(true /* defer */,
ThumbnailData thumbnail = mRecentsAnimationController.screenshotTask(mRunningTaskId);
mRecentsAnimationController.setDeferCancelUntilNextTransition(true /* defer */,
false /* screenshot */);
ActivityOptions options = ActivityOptions.makeCustomAnimation(mContext, 0, 0);
@ -350,7 +351,7 @@ public class FallbackNoButtonInputConsumer extends
Intent intent = new Intent(mOverviewComponentObserver.getOverviewIntent())
.putExtras(extras);
mContext.startActivity(intent, options.toBundle());
mRecentsAnimationWrapper.cleanupScreenshot();
mRecentsAnimationController.cleanupScreenshot();
break;
}
case NEW_TASK: {
@ -416,10 +417,10 @@ public class FallbackNoButtonInputConsumer extends
}
@Override
public void onRecentsAnimationStart(RecentsAnimationWrapper controller,
RecentsAnimationTargets targetSet) {
super.onRecentsAnimationStart(controller, targetSet);
mRecentsAnimationWrapper.enableInputConsumer();
public void onRecentsAnimationStart(RecentsAnimationController controller,
RecentsAnimationTargets targets) {
super.onRecentsAnimationStart(controller, targets);
mRecentsAnimationController.enableInputConsumer();
if (mRunningOverHome) {
mAppWindowAnimationHelper.prepareAnimation(mDp, true);

View File

@ -53,6 +53,7 @@ import com.android.launcher3.util.TraceHelper;
import com.android.quickstep.ActivityControlHelper;
import com.android.quickstep.BaseSwipeUpHandler;
import com.android.quickstep.BaseSwipeUpHandler.Factory;
import com.android.quickstep.InputConsumer;
import com.android.quickstep.RecentsAnimationDeviceState;
import com.android.quickstep.SwipeSharedState;
import com.android.quickstep.SysUINavigationMode;
@ -61,7 +62,7 @@ import com.android.quickstep.util.ActiveGestureLog;
import com.android.quickstep.util.CachedEventDispatcher;
import com.android.quickstep.util.MotionPauseDetector;
import com.android.quickstep.util.NavBarPosition;
import com.android.quickstep.util.RecentsAnimationCallbacks;
import com.android.quickstep.RecentsAnimationCallbacks;
import com.android.systemui.shared.system.ActivityManagerWrapper;
import com.android.systemui.shared.system.InputMonitorCompat;
@ -343,12 +344,11 @@ public class OtherActivityInputConsumer extends ContextWrapper implements InputC
mSwipeSharedState.applyActiveRecentsAnimationState(handler);
notifyGestureStarted();
} else {
RecentsAnimationCallbacks newListenerSet =
mSwipeSharedState.newRecentsAnimationListenerSet();
newListenerSet.addListener(handler);
RecentsAnimationCallbacks callbacks = mSwipeSharedState.newRecentsAnimationCallbacks();
callbacks.addListener(handler);
Intent intent = handler.getLaunchIntent();
intent.putExtra(INTENT_EXTRA_LOG_TRACE_ID, mLogId);
startRecentsActivityAsync(intent, newListenerSet);
startRecentsActivityAsync(intent, callbacks);
}
}

View File

@ -27,6 +27,7 @@ import com.android.launcher3.BaseDraggingActivity;
import com.android.launcher3.Utilities;
import com.android.launcher3.views.BaseDragLayer;
import com.android.quickstep.ActivityControlHelper;
import com.android.quickstep.InputConsumer;
import com.android.quickstep.util.ActiveGestureLog;
import com.android.systemui.shared.system.ActivityManagerWrapper;
import com.android.systemui.shared.system.InputMonitorCompat;

View File

@ -36,6 +36,7 @@ import com.android.launcher3.logging.StatsLogUtils;
import com.android.launcher3.userevent.nano.LauncherLogProto.Action.Direction;
import com.android.launcher3.userevent.nano.LauncherLogProto.Action.Touch;
import com.android.quickstep.ActivityControlHelper;
import com.android.quickstep.InputConsumer;
import com.android.quickstep.util.ActiveGestureLog;
import com.android.quickstep.util.NavBarPosition;
import com.android.systemui.shared.system.ActivityManagerWrapper;

View File

@ -36,6 +36,7 @@ import android.view.ViewConfiguration;
import com.android.launcher3.BaseDraggingActivity;
import com.android.launcher3.R;
import com.android.quickstep.ActivityControlHelper;
import com.android.quickstep.InputConsumer;
import com.android.quickstep.views.RecentsView;
import com.android.systemui.shared.system.InputMonitorCompat;

View File

@ -17,6 +17,7 @@ package com.android.quickstep.inputconsumers;
import android.view.MotionEvent;
import com.android.quickstep.InputConsumer;
import com.android.quickstep.SwipeSharedState;
/**

View File

@ -22,6 +22,7 @@ import android.view.MotionEvent;
import com.android.launcher3.BaseDraggingActivity;
import com.android.launcher3.R;
import com.android.quickstep.ActivityControlHelper;
import com.android.quickstep.InputConsumer;
import com.android.quickstep.util.MotionPauseDetector;
import com.android.quickstep.SystemUiProxy;

View File

@ -35,6 +35,7 @@ import com.android.launcher3.BaseDraggingActivity;
import com.android.launcher3.DeviceProfile;
import com.android.launcher3.LauncherState;
import com.android.launcher3.R;
import com.android.quickstep.RemoteAnimationTargets;
import com.android.quickstep.SystemUiProxy;
import com.android.launcher3.Utilities;
import com.android.launcher3.views.BaseDragLayer;

View File

@ -220,7 +220,7 @@ public class LauncherRecentsView extends RecentsView<Launcher> implements StateL
@Override
public AppWindowAnimationHelper.TransformParams getLiveTileParams(
boolean mightNeedToRefill) {
if (!mEnableDrawingLiveTile || mRecentsAnimationWrapper == null
if (!mEnableDrawingLiveTile || mRecentsAnimationController == null
|| mRecentsAnimationTargets == null || mAppWindowAnimationHelper == null) {
return null;
}

View File

@ -101,14 +101,14 @@ import com.android.launcher3.util.OverScroller;
import com.android.launcher3.util.PendingAnimation;
import com.android.launcher3.util.Themes;
import com.android.launcher3.util.ViewPool;
import com.android.quickstep.RecentsAnimationWrapper;
import com.android.quickstep.RecentsAnimationController;
import com.android.quickstep.RecentsModel;
import com.android.quickstep.RecentsModel.TaskThumbnailChangeListener;
import com.android.quickstep.TaskThumbnailCache;
import com.android.quickstep.TaskUtils;
import com.android.quickstep.ViewUtils;
import com.android.quickstep.util.AppWindowAnimationHelper;
import com.android.quickstep.util.RecentsAnimationTargets;
import com.android.quickstep.RecentsAnimationTargets;
import com.android.systemui.shared.recents.model.Task;
import com.android.systemui.shared.recents.model.ThumbnailData;
import com.android.systemui.shared.system.ActivityManagerWrapper;
@ -156,7 +156,7 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
}
};
protected RecentsAnimationWrapper mRecentsAnimationWrapper;
protected RecentsAnimationController mRecentsAnimationController;
protected RecentsAnimationTargets mRecentsAnimationTargets;
protected AppWindowAnimationHelper mAppWindowAnimationHelper;
protected SyncRtSurfaceTransactionApplierCompat mSyncTransactionApplier;
@ -809,7 +809,7 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
mIgnoreResetTaskId = -1;
mTaskListChangeId = -1;
mRecentsAnimationWrapper = null;
mRecentsAnimationController = null;
mRecentsAnimationTargets = null;
mAppWindowAnimationHelper = null;
@ -1696,9 +1696,9 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
public void redrawLiveTile(boolean mightNeedToRefill) { }
// TODO: To be removed in a follow up CL
public void setRecentsAnimationTargets(RecentsAnimationWrapper recentsAnimationWrapper,
public void setRecentsAnimationTargets(RecentsAnimationController recentsAnimationController,
RecentsAnimationTargets recentsAnimationTargets) {
mRecentsAnimationWrapper = recentsAnimationWrapper;
mRecentsAnimationController = recentsAnimationController;
mRecentsAnimationTargets = recentsAnimationTargets;
}
@ -1718,14 +1718,14 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
}
public void finishRecentsAnimation(boolean toRecents, Runnable onFinishComplete) {
if (mRecentsAnimationWrapper == null) {
if (mRecentsAnimationController == null) {
if (onFinishComplete != null) {
onFinishComplete.run();
}
return;
}
mRecentsAnimationWrapper.finish(toRecents, onFinishComplete);
mRecentsAnimationController.finish(toRecents, onFinishComplete);
}
public void setDisallowScrollToClearAll(boolean disallowScrollToClearAll) {

View File

@ -71,7 +71,7 @@ import com.android.launcher3.util.MultiValueAlpha.AlphaProperty;
import com.android.launcher3.views.FloatingIconView;
import com.android.quickstep.util.MultiValueUpdateListener;
import com.android.quickstep.util.RemoteAnimationProvider;
import com.android.quickstep.util.RemoteAnimationTargets;
import com.android.quickstep.RemoteAnimationTargets;
import com.android.systemui.shared.system.ActivityCompat;
import com.android.systemui.shared.system.ActivityOptionsCompat;
import com.android.systemui.shared.system.QuickStepContract;

View File

@ -32,7 +32,6 @@ import com.android.launcher3.BaseDraggingActivity;
import com.android.launcher3.DeviceProfile;
import com.android.launcher3.anim.AnimatorPlaybackController;
import com.android.quickstep.util.ActivityInitListener;
import com.android.quickstep.util.RemoteAnimationTargets;
import com.android.systemui.shared.recents.model.ThumbnailData;
import com.android.systemui.shared.system.RemoteAnimationTargetCompat;

View File

@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.android.quickstep.inputconsumers;
package com.android.quickstep;
import android.annotation.TargetApi;
import android.os.Build;

View File

@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.android.quickstep.util;
package com.android.quickstep;
import static com.android.launcher3.util.Executors.MAIN_EXECUTOR;
@ -25,8 +25,6 @@ import androidx.annotation.UiThread;
import com.android.launcher3.Utilities;
import com.android.launcher3.util.Preconditions;
import com.android.quickstep.TouchInteractionService;
import com.android.quickstep.RecentsAnimationWrapper;
import com.android.systemui.shared.recents.model.ThumbnailData;
import com.android.systemui.shared.system.RecentsAnimationControllerCompat;
import com.android.systemui.shared.system.RemoteAnimationTargetCompat;
@ -44,7 +42,7 @@ public class RecentsAnimationCallbacks implements
private final boolean mShouldMinimizeSplitScreen;
// TODO(141886704): Remove these references when they are no longer needed
private RecentsAnimationWrapper mController;
private RecentsAnimationController mController;
private boolean mCancelled;
@ -85,10 +83,10 @@ public class RecentsAnimationCallbacks implements
RemoteAnimationTargetCompat[] appTargets,
RemoteAnimationTargetCompat[] wallpaperTargets,
Rect homeContentInsets, Rect minimizedHomeBounds) {
RecentsAnimationTargets targetSet = new RecentsAnimationTargets(appTargets,
RecentsAnimationTargets targets = new RecentsAnimationTargets(appTargets,
wallpaperTargets, homeContentInsets, minimizedHomeBounds);
mController = new RecentsAnimationWrapper(animationController, mShouldMinimizeSplitScreen,
this::onAnimationFinished);
mController = new RecentsAnimationController(animationController,
mShouldMinimizeSplitScreen, this::onAnimationFinished);
if (mCancelled) {
Utilities.postAsyncCallback(MAIN_EXECUTOR.getHandler(),
@ -96,7 +94,7 @@ public class RecentsAnimationCallbacks implements
} else {
Utilities.postAsyncCallback(MAIN_EXECUTOR.getHandler(), () -> {
for (RecentsAnimationListener listener : getListeners()) {
listener.onRecentsAnimationStart(mController, targetSet);
listener.onRecentsAnimationStart(mController, targets);
}
});
}
@ -112,7 +110,7 @@ public class RecentsAnimationCallbacks implements
});
}
private final void onAnimationFinished(RecentsAnimationWrapper controller) {
private final void onAnimationFinished(RecentsAnimationController controller) {
Utilities.postAsyncCallback(MAIN_EXECUTOR.getHandler(), () -> {
for (RecentsAnimationListener listener : getListeners()) {
listener.onRecentsAnimationFinished(controller);
@ -128,7 +126,7 @@ public class RecentsAnimationCallbacks implements
* Listener for the recents animation callbacks.
*/
public interface RecentsAnimationListener {
default void onRecentsAnimationStart(RecentsAnimationWrapper controller,
default void onRecentsAnimationStart(RecentsAnimationController controller,
RecentsAnimationTargets targetSet) {}
/**
@ -137,6 +135,6 @@ public class RecentsAnimationCallbacks implements
*/
default void onRecentsAnimationCanceled(ThumbnailData thumbnailData) {}
default void onRecentsAnimationFinished(RecentsAnimationWrapper controller) {}
default void onRecentsAnimationFinished(RecentsAnimationController controller) {}
}
}

View File

@ -30,12 +30,8 @@ import android.view.MotionEvent;
import androidx.annotation.UiThread;
import com.android.launcher3.util.Preconditions;
import com.android.quickstep.inputconsumers.InputConsumer;
import com.android.quickstep.util.RecentsAnimationCallbacks;
import com.android.quickstep.util.RecentsAnimationTargets;
import com.android.systemui.shared.recents.model.ThumbnailData;
import com.android.systemui.shared.system.InputConsumerController;
import com.android.systemui.shared.system.RecentsAnimationControllerCompat;
import java.util.function.Consumer;
@ -44,12 +40,12 @@ import java.util.function.Supplier;
/**
* Wrapper around RecentsAnimationController to help with some synchronization
*/
public class RecentsAnimationWrapper {
public class RecentsAnimationController {
private static final String TAG = "RecentsAnimationWrapper";
private static final String TAG = "RecentsAnimationController";
private final RecentsAnimationControllerCompat mController;
private final Consumer<RecentsAnimationWrapper> mOnFinishedListener;
private final Consumer<RecentsAnimationController> mOnFinishedListener;
private final boolean mShouldMinimizeSplitScreen;
private boolean mWindowThresholdCrossed = false;
@ -60,9 +56,9 @@ public class RecentsAnimationWrapper {
private boolean mTouchInProgress;
private boolean mFinishPending;
public RecentsAnimationWrapper(RecentsAnimationControllerCompat controller,
public RecentsAnimationController(RecentsAnimationControllerCompat controller,
boolean shouldMinimizeSplitScreen,
Consumer<RecentsAnimationWrapper> onFinishedListener) {
Consumer<RecentsAnimationController> onFinishedListener) {
mController = controller;
mOnFinishedListener = onFinishedListener;
mShouldMinimizeSplitScreen = shouldMinimizeSplitScreen;

View File

@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.android.quickstep.util;
package com.android.quickstep;
import static com.android.systemui.shared.system.RemoteAnimationTargetCompat.MODE_CLOSING;

View File

@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.android.quickstep.util;
package com.android.quickstep;
import com.android.systemui.shared.system.RemoteAnimationTargetCompat;
import com.android.systemui.shared.system.SyncRtSurfaceTransactionApplierCompat;

View File

@ -21,6 +21,7 @@ import static com.android.systemui.shared.system.RemoteAnimationTargetCompat.MOD
import android.animation.ValueAnimator;
import android.animation.ValueAnimator.AnimatorUpdateListener;
import com.android.quickstep.RemoteAnimationTargets;
import com.android.systemui.shared.system.RemoteAnimationTargetCompat;
import com.android.systemui.shared.system.TransactionCompat;