From 3eeaea8befcea6e706e6bf414ee915207c599ef1 Mon Sep 17 00:00:00 2001 From: Michael Jurka Date: Mon, 31 Jan 2011 15:02:36 -0800 Subject: [PATCH] Using hardware layers for animations to all apps/customize - improves performance of All Apps transition in portrait --- src/com/android/launcher2/Launcher.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/com/android/launcher2/Launcher.java b/src/com/android/launcher2/Launcher.java index f3208d0b88..3874686998 100644 --- a/src/com/android/launcher2/Launcher.java +++ b/src/com/android/launcher2/Launcher.java @@ -2690,6 +2690,7 @@ public final class Launcher extends Activity } scaleAnim.setInterpolator(new Workspace.ZoomOutInterpolator()); + toView.setLayerType(View.LAYER_TYPE_HARDWARE, null); scaleAnim.addListener(new AnimatorListenerAdapter() { @Override public void onAnimationStart(Animator animation) { @@ -2706,6 +2707,7 @@ public final class Launcher extends Activity // If we don't set the final scale values here, if this animation is cancelled // it will have the wrong scale value and subsequent cameraPan animations will // not fix that + toView.setLayerType(View.LAYER_TYPE_NONE, null); toView.setScaleX(1.0f); toView.setScaleY(1.0f); }