summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/LauncherAnimUtils.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/com/android/launcher3/LauncherAnimUtils.java')
-rw-r--r--src/com/android/launcher3/LauncherAnimUtils.java15
1 files changed, 13 insertions, 2 deletions
diff --git a/src/com/android/launcher3/LauncherAnimUtils.java b/src/com/android/launcher3/LauncherAnimUtils.java
index aa7f5ee5f..cfb9b570b 100644
--- a/src/com/android/launcher3/LauncherAnimUtils.java
+++ b/src/com/android/launcher3/LauncherAnimUtils.java
@@ -21,11 +21,10 @@ import android.animation.AnimatorSet;
import android.animation.ObjectAnimator;
import android.animation.PropertyValuesHolder;
import android.animation.ValueAnimator;
+import android.graphics.drawable.Drawable;
import android.util.Property;
import android.view.View;
-import android.view.ViewGroup;
import android.view.ViewTreeObserver;
-import android.widget.ViewAnimator;
import java.util.HashSet;
import java.util.WeakHashMap;
@@ -130,4 +129,16 @@ public class LauncherAnimUtils {
return anim;
}
+ public static final Property<Drawable, Integer> DRAWABLE_ALPHA =
+ new Property<Drawable, Integer>(Integer.TYPE, "drawableAlpha") {
+ @Override
+ public Integer get(Drawable drawable) {
+ return drawable.getAlpha();
+ }
+
+ @Override
+ public void set(Drawable drawable, Integer alpha) {
+ drawable.setAlpha(alpha);
+ }
+ };
}