Starting the dismiss animation in parallel with the gesture.
- Introduces notion of ignored tasks for the purposes of layout in
TaskStackView. This can be used during drag and drop, and while
dismissing to calculate the state of the stack without the task that
the user is currently interacting with.
- Fixing minor layout issue when the front/back task transforms are
improperly calculated when there is a single task
- Fixing minor issue when the anchor task is calculated incorrectly when
dismissing task views
Change-Id: I1eb0864a52e53562e4d573a6ed4f8a5a1615aff9
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java b/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java
index e727652..e448101 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java
@@ -513,7 +513,7 @@
taskViewRect.right, taskViewRect.bottom);
// Remove the task view after it is docked
- mTaskStackView.updateLayout(false /* boundScroll */);
+ mTaskStackView.updateLayoutAlgorithm(false /* boundScroll */);
stackLayout.getStackTransform(event.task, stackScroller.getStackScroll(), tmpTransform,
null);
tmpTransform.alpha = 0;
@@ -529,11 +529,14 @@
ssp.startTaskInDockedMode(getContext(), event.taskView,
event.task.key.id, dockState.createMode);
- mTaskStackView.getStack().removeTask(event.task);
+ // Animate the stack accordingly
+ TaskViewAnimation stackAnim = new TaskViewAnimation(
+ TaskStackView.DEFAULT_SYNC_STACK_DURATION,
+ mFastOutSlowInInterpolator);
+ mTaskStackView.getStack().removeTask(event.task, stackAnim);
}
}));
-
MetricsLogger.action(mContext,
MetricsLogger.ACTION_WINDOW_DOCK_DRAG_DROP);
} else {