summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/WorkspaceStateTransitionAnimation.java
diff options
context:
space:
mode:
authorSunny Goyal <sunnygoyal@google.com>2015-06-05 00:13:25 -0700
committerSunny Goyal <sunnygoyal@google.com>2015-06-05 00:34:06 -0700
commit4f3e9383eb422c87e2689548653b89f34f5516a5 (patch)
treefe42f1800be1eabeac6498e0bfb14f91b2b77ba2 /src/com/android/launcher3/WorkspaceStateTransitionAnimation.java
parent26c2842f07668385b8f4594848cf6e93502da4a3 (diff)
downloadandroid_packages_apps_Trebuchet-4f3e9383eb422c87e2689548653b89f34f5516a5.tar.gz
android_packages_apps_Trebuchet-4f3e9383eb422c87e2689548653b89f34f5516a5.tar.bz2
android_packages_apps_Trebuchet-4f3e9383eb422c87e2689548653b89f34f5516a5.zip
Code cleanup
> Removing obsolete logging > Removing unused methods > Removing resource leak warning due to non-static handler class in launcher Change-Id: Ic38cc8aea82899b0b5ee3235f04e5964e49245fb
Diffstat (limited to 'src/com/android/launcher3/WorkspaceStateTransitionAnimation.java')
-rw-r--r--src/com/android/launcher3/WorkspaceStateTransitionAnimation.java11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/com/android/launcher3/WorkspaceStateTransitionAnimation.java b/src/com/android/launcher3/WorkspaceStateTransitionAnimation.java
index 340066d64..e360e889b 100644
--- a/src/com/android/launcher3/WorkspaceStateTransitionAnimation.java
+++ b/src/com/android/launcher3/WorkspaceStateTransitionAnimation.java
@@ -19,6 +19,7 @@ package com.android.launcher3;
import android.animation.Animator;
import android.animation.AnimatorListenerAdapter;
import android.animation.AnimatorSet;
+import android.animation.ObjectAnimator;
import android.animation.TimeInterpolator;
import android.animation.ValueAnimator;
import android.content.Context;
@@ -335,17 +336,11 @@ public class WorkspaceStateTransitionAnimation {
}
if (mOldBackgroundAlphas[i] != 0 ||
mNewBackgroundAlphas[i] != 0) {
- ValueAnimator bgAnim =
+ ValueAnimator bgAnim = ObjectAnimator.ofFloat(cl, "backgroundAlpha",
+ mOldBackgroundAlphas[i], mNewBackgroundAlphas[i]);
LauncherAnimUtils.ofFloat(cl, 0f, 1f);
bgAnim.setInterpolator(mZoomInInterpolator);
bgAnim.setDuration(duration);
- bgAnim.addUpdateListener(new LauncherAnimatorUpdateListener() {
- public void onAnimationUpdate(float a, float b) {
- cl.setBackgroundAlpha(
- a * mOldBackgroundAlphas[i] +
- b * mNewBackgroundAlphas[i]);
- }
- });
mStateAnimator.play(bgAnim);
}
}