Allow split with an existing split task

- Determine the task in the group being clicked in split-select mode
  and launch split using that selected task
- Also make sure we don't handle drag cancel twice when we are animating
  the return of the drag surface

Bug: 219060441
Test: Split from home/overview with fullscreen+fullscreen task, and with
      fullscreen+split task

Change-Id: I48ec0a82812197803ff4b3698830a9cb705719e3
This commit is contained in:
Winson Chung
2022-02-17 23:26:12 +00:00
parent da7a268e7f
commit 3516ecc534
5 changed files with 73 additions and 38 deletions

View File

@@ -469,13 +469,19 @@ public class TaskbarDragController extends DragController<TaskbarActivityContext
}
});
mReturnAnimator.addListener(new AnimatorListenerAdapter() {
private boolean mCanceled = false;
@Override
public void onAnimationCancel(Animator animation) {
cleanUpSurface();
mCanceled = true;
}
@Override
public void onAnimationEnd(Animator animation) {
if (mCanceled) {
return;
}
cleanUpSurface();
}