Loading src/com/android/launcher3/folder/Folder.java +3 −0 Original line number Diff line number Diff line Loading @@ -790,6 +790,9 @@ public class Folder extends AbstractFloatingView implements DragSource, View.OnC mFolderIcon.setVisibility(View.VISIBLE); if (wasAnimated) { mFolderIcon.mBackground.animateBackgroundStroke(); if (mFolderIcon.hasBadge()) { mFolderIcon.createBadgeScaleAnimator(0f, 1f).start(); } mFolderIcon.requestFocus(); } } Loading src/com/android/launcher3/folder/FolderIcon.java +9 −3 Original line number Diff line number Diff line Loading @@ -38,8 +38,6 @@ import android.graphics.drawable.Drawable; import android.os.Parcelable; import android.support.v4.graphics.ColorUtils; import android.util.AttributeSet; import android.util.DisplayMetrics; import android.util.Log; import android.util.Property; import android.view.LayoutInflater; import android.view.MotionEvent; Loading Loading @@ -421,13 +419,21 @@ public class FolderIcon extends FrameLayout implements FolderListener { float newBadgeScale = isBadged ? 1f : 0f; // Animate when a badge is first added or when it is removed. if ((wasBadged ^ isBadged) && isShown()) { ObjectAnimator.ofFloat(this, BADGE_SCALE_PROPERTY, newBadgeScale).start(); createBadgeScaleAnimator(newBadgeScale).start(); } else { mBadgeScale = newBadgeScale; invalidate(); } } public Animator createBadgeScaleAnimator(float... badgeScales) { return ObjectAnimator.ofFloat(this, BADGE_SCALE_PROPERTY, badgeScales); } public boolean hasBadge() { return mBadgeInfo != null && mBadgeInfo.hasBadge(); } static class PreviewItemDrawingParams { PreviewItemDrawingParams(float transX, float transY, float scale, float overlayAlpha) { this.transX = transX; Loading Loading
src/com/android/launcher3/folder/Folder.java +3 −0 Original line number Diff line number Diff line Loading @@ -790,6 +790,9 @@ public class Folder extends AbstractFloatingView implements DragSource, View.OnC mFolderIcon.setVisibility(View.VISIBLE); if (wasAnimated) { mFolderIcon.mBackground.animateBackgroundStroke(); if (mFolderIcon.hasBadge()) { mFolderIcon.createBadgeScaleAnimator(0f, 1f).start(); } mFolderIcon.requestFocus(); } } Loading
src/com/android/launcher3/folder/FolderIcon.java +9 −3 Original line number Diff line number Diff line Loading @@ -38,8 +38,6 @@ import android.graphics.drawable.Drawable; import android.os.Parcelable; import android.support.v4.graphics.ColorUtils; import android.util.AttributeSet; import android.util.DisplayMetrics; import android.util.Log; import android.util.Property; import android.view.LayoutInflater; import android.view.MotionEvent; Loading Loading @@ -421,13 +419,21 @@ public class FolderIcon extends FrameLayout implements FolderListener { float newBadgeScale = isBadged ? 1f : 0f; // Animate when a badge is first added or when it is removed. if ((wasBadged ^ isBadged) && isShown()) { ObjectAnimator.ofFloat(this, BADGE_SCALE_PROPERTY, newBadgeScale).start(); createBadgeScaleAnimator(newBadgeScale).start(); } else { mBadgeScale = newBadgeScale; invalidate(); } } public Animator createBadgeScaleAnimator(float... badgeScales) { return ObjectAnimator.ofFloat(this, BADGE_SCALE_PROPERTY, badgeScales); } public boolean hasBadge() { return mBadgeInfo != null && mBadgeInfo.hasBadge(); } static class PreviewItemDrawingParams { PreviewItemDrawingParams(float transX, float transY, float scale, float overlayAlpha) { this.transX = transX; Loading