diff --git a/quickstep/src/com/android/quickstep/BaseActivityInterface.java b/quickstep/src/com/android/quickstep/BaseActivityInterface.java index d7ff8ab3fc..3e565b3697 100644 --- a/quickstep/src/com/android/quickstep/BaseActivityInterface.java +++ b/quickstep/src/com/android/quickstep/BaseActivityInterface.java @@ -349,6 +349,13 @@ public abstract class BaseActivityInterface focusedTaskIndex) { diff --git a/quickstep/src/com/android/quickstep/views/TaskView.java b/quickstep/src/com/android/quickstep/views/TaskView.java index b9aaef63ca..ab72f2d10e 100644 --- a/quickstep/src/com/android/quickstep/views/TaskView.java +++ b/quickstep/src/com/android/quickstep/views/TaskView.java @@ -1619,7 +1619,12 @@ public class TaskView extends FrameLayout implements Reusable { int boxWidth; int boxHeight; boolean isFocusedTask = isFocusedTask(); - if (isFocusedTask || isDesktopTask()) { + if (isDesktopTask()) { + Rect lastComputedDesktopTaskSize = + getRecentsView().getLastComputedDesktopTaskSize(); + boxWidth = lastComputedDesktopTaskSize.width(); + boxHeight = lastComputedDesktopTaskSize.height(); + } else if (isFocusedTask) { // Task will be focused and should use focused task size. Use focusTaskRatio // that is associated with the original orientation of the focused task. boxWidth = taskWidth;