summaryrefslogtreecommitdiffstats
path: root/quickstep
diff options
context:
space:
mode:
authorSunny Goyal <sunnygoyal@google.com>2018-05-14 11:08:05 -0700
committerSunny Goyal <sunnygoyal@google.com>2018-05-14 11:08:41 -0700
commit55631dd8afbc52c83c50a5ade0fe28a454d86862 (patch)
tree5f4b5529e2ff9dc93e9646f741925e221a02135e /quickstep
parent99dcc9fd8317447c55866e571057160477a7a283 (diff)
downloadandroid_packages_apps_Trebuchet-55631dd8afbc52c83c50a5ade0fe28a454d86862.tar.gz
android_packages_apps_Trebuchet-55631dd8afbc52c83c50a5ade0fe28a454d86862.tar.bz2
android_packages_apps_Trebuchet-55631dd8afbc52c83c50a5ade0fe28a454d86862.zip
Fixing task location calculation in seascape
> In seascape, the task is aligned to the left insets Change-Id: I2bc090698320045a014dc713d57ca412a58bf9e4
Diffstat (limited to 'quickstep')
-rw-r--r--quickstep/src/com/android/quickstep/util/ClipAnimationHelper.java7
1 files changed, 4 insertions, 3 deletions
diff --git a/quickstep/src/com/android/quickstep/util/ClipAnimationHelper.java b/quickstep/src/com/android/quickstep/util/ClipAnimationHelper.java
index 14b40467f..a25b77d3d 100644
--- a/quickstep/src/com/android/quickstep/util/ClipAnimationHelper.java
+++ b/quickstep/src/com/android/quickstep/util/ClipAnimationHelper.java
@@ -250,10 +250,11 @@ public class ClipAnimationHelper {
taskHeight = taskHeight / 2 - halfDividerSize;
}
+ // Align the task to bottom left/right edge (closer to nav bar).
+ int left = activity.getDeviceProfile().isSeascape() ? insets.left
+ : (insets.left + fullDp.availableWidthPx - taskWidth);
mSourceStackBounds.set(0, 0, taskWidth, taskHeight);
- // Align the task to bottom right (probably not true for seascape).
- mSourceStackBounds.offset(insets.left + fullDp.availableWidthPx - taskWidth,
- insets.top + fullDp.availableHeightPx - taskHeight);
+ mSourceStackBounds.offset(left, insets.top + fullDp.availableHeightPx - taskHeight);
}
public void drawForProgress(TaskThumbnailView ttv, Canvas canvas, float progress) {