Merge "Remove canStartRecentsAnimation logics" into rvc-dev am: 715d65f9c7

Change-Id: Ia9e3478a21b68204638cdf5c4d2d65f869602ce2
This commit is contained in:
TreeHugger Robot
2020-04-16 09:05:12 +00:00
committed by Automerger Merge Worker
3 changed files with 0 additions and 24 deletions

View File

@@ -165,17 +165,6 @@ class RecentsAnimation implements RecentsAnimationCallbacks,
ProtoLog.d(WM_DEBUG_RECENTS_ANIMATIONS, "startRecentsActivity(): intent=%s", mTargetIntent);
Trace.traceBegin(TRACE_TAG_WINDOW_MANAGER, "RecentsAnimation#startRecentsActivity");
// TODO(multi-display) currently only support recents animation in default display.
final DisplayContent dc =
mService.mRootWindowContainer.getDefaultDisplay().mDisplayContent;
if (!mWindowManager.canStartRecentsAnimation()) {
notifyAnimationCancelBeforeStart(recentsAnimationRunner);
ProtoLog.d(WM_DEBUG_RECENTS_ANIMATIONS,
"Can't start recents animation, nextAppTransition=%s",
dc.mAppTransition.getAppTransition());
return;
}
// If the activity is associated with the recents stack, then try and get that first
ActivityStack targetStack = mDefaultTaskDisplayArea.getStack(WINDOWING_MODE_UNDEFINED,
mTargetActivityType);

View File

@@ -2797,18 +2797,6 @@ public class WindowManagerService extends IWindowManager.Stub
return mRecentsAnimationController;
}
/**
* @return Whether the next recents animation can continue to start. Called from
* {@link RecentsAnimation#startRecentsActivity}.
*/
boolean canStartRecentsAnimation() {
// TODO(multi-display): currently only default display support recent activity
if (getDefaultDisplayContentLocked().mAppTransition.isTransitionSet()) {
return false;
}
return true;
}
void cancelRecentsAnimation(
@RecentsAnimationController.ReorderMode int reorderMode, String reason) {
if (mRecentsAnimationController != null) {

View File

@@ -79,7 +79,6 @@ public class RecentsAnimationTest extends ActivityTestsBase {
mService.mWindowManager.setRecentsAnimationController(mRecentsAnimationController);
doNothing().when(mService.mWindowManager).initializeRecentsAnimation(
anyInt(), any(), any(), anyInt(), any(), any());
doReturn(true).when(mService.mWindowManager).canStartRecentsAnimation();
final RecentTasks recentTasks = mService.getRecentTasks();
spyOn(recentTasks);