am 1772df64: am aa1e5728: Merge "Small fix to deal with ugly widget dropping situations" into ics-mr1

* commit '1772df6467d02e400dc61a2bee50f43bdff72782':
  Small fix to deal with ugly widget dropping situations
This commit is contained in:
Adam Cohen
2011-11-18 15:22:38 -08:00
committed by Android Git Automerger
+2 -1
View File
@@ -2960,7 +2960,8 @@ public class Workspace extends SmoothPagedView
mLauncher.getDragLayer().getDescendantCoordRelativeToSelf(cellLayout, loc);
resetTransitionTransform(cellLayout);
float dragViewScale = r.width() / d.dragView.getMeasuredWidth();
float dragViewScale = Math.min(r.width() / d.dragView.getMeasuredWidth(),
r.height() / d.dragView.getMeasuredHeight());
// The animation will scale the dragView about its center, so we need to center about
// the final location.
loc[0] -= (d.dragView.getMeasuredWidth() - cellLayoutScale * r.width()) / 2;