diff options
author | Adam Cohen <adamcohen@google.com> | 2012-08-16 17:55:58 -0700 |
---|---|---|
committer | Adam Cohen <adamcohen@google.com> | 2012-08-20 21:49:43 -0700 |
commit | 307fe23f125cbbd5512ad8d4660025f2ab68f30b (patch) | |
tree | 0bb74d508939237e628e96fade69d3b5ccf3c07b /src/com/android/launcher2/DragView.java | |
parent | 5c768e2fac95f8b8b2d6b5c523d7e1cdc968e395 (diff) | |
download | android_packages_apps_Trebuchet-307fe23f125cbbd5512ad8d4660025f2ab68f30b.tar.gz android_packages_apps_Trebuchet-307fe23f125cbbd5512ad8d4660025f2ab68f30b.tar.bz2 android_packages_apps_Trebuchet-307fe23f125cbbd5512ad8d4660025f2ab68f30b.zip |
Adding the ability to scale the hotseat or items in the hotseat
--> A bunch of stuff breaks when scaling the hotseat. More specifically,
drag and drop animations between hotseat and workspace,
scaling on pick up, folder animations, determination of
item placement. This CL fixes these issues so that the
hotseat or hotseat items are ready to be scaled.
--> For now, using 90% scale factor for 7-inch+ UIs
Change-Id: Iac098409347e76139e4d726a071397b56ac684d2
Diffstat (limited to 'src/com/android/launcher2/DragView.java')
-rw-r--r-- | src/com/android/launcher2/DragView.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/com/android/launcher2/DragView.java b/src/com/android/launcher2/DragView.java index 389421d52..e6b15b8ee 100644 --- a/src/com/android/launcher2/DragView.java +++ b/src/com/android/launcher2/DragView.java @@ -75,6 +75,10 @@ public class DragView extends View { final float scaleDps = res.getDimensionPixelSize(R.dimen.dragViewScale); final float scale = (width + scaleDps) / width; + // Set the initial scale to avoid any jumps + setScaleX(initialScale); + setScaleY(initialScale); + // Animate the view into the correct position mAnim = LauncherAnimUtils.ofFloat(0.0f, 1.0f); mAnim.setDuration(150); |