Search in sources :

Example 6 with RectFSpringAnim

use of com.android.quickstep.util.RectFSpringAnim in project android_packages_apps_Launcher3 by crdroidandroid.

the class SwipeUpGestureTutorialController method animateFakeTaskViewHome.

void animateFakeTaskViewHome(PointF finalVelocity, @Nullable Runnable onEndRunnable) {
    hideFeedback(true);
    cancelRunningAnimation();
    mFakePreviousTaskView.setVisibility(View.INVISIBLE);
    mFakeHotseatView.setVisibility(View.VISIBLE);
    mShowPreviousTasks = false;
    RectFSpringAnim rectAnim = mTaskViewSwipeUpAnimation.handleSwipeUpToHome(finalVelocity);
    // After home animation finishes, fade out and run onEndRunnable.
    PendingAnimation fadeAnim = new PendingAnimation(300);
    fadeAnim.setViewAlpha(mFakeIconView, 0, ACCEL);
    if (onEndRunnable != null) {
        fadeAnim.addListener(AnimatorListeners.forSuccessCallback(onEndRunnable));
    }
    AnimatorSet animset = fadeAnim.buildAnim();
    rectAnim.addAnimatorListener(AnimatorListeners.forSuccessCallback(animset::start));
    mRunningWindowAnim = RunningWindowAnim.wrap(rectAnim);
}
Also used : RectFSpringAnim(com.android.quickstep.util.RectFSpringAnim) PendingAnimation(com.android.launcher3.anim.PendingAnimation) AnimatorSet(android.animation.AnimatorSet)

Aggregations

RectFSpringAnim (com.android.quickstep.util.RectFSpringAnim)6 RectF (android.graphics.RectF)3 AnimatorSet (android.animation.AnimatorSet)2 Nullable (androidx.annotation.Nullable)2 AppCloseConfig (com.android.quickstep.util.AppCloseConfig)2 Animator (android.animation.Animator)1 ValueAnimator (android.animation.ValueAnimator)1 Matrix (android.graphics.Matrix)1 Rect (android.graphics.Rect)1 IBinder (android.os.IBinder)1 Size (android.util.Size)1 UiThread (androidx.annotation.UiThread)1 AnimationSuccessListener (com.android.launcher3.anim.AnimationSuccessListener)1 PendingAnimation (com.android.launcher3.anim.PendingAnimation)1 FloatingIconView (com.android.launcher3.views.FloatingIconView)1 FloatingIconView.getFloatingIconView (com.android.launcher3.views.FloatingIconView.getFloatingIconView)1 RectFSpringAnim2 (com.android.quickstep.util.RectFSpringAnim2)1 SwipePipToHomeAnimator (com.android.quickstep.util.SwipePipToHomeAnimator)1 FloatingWidgetView (com.android.quickstep.views.FloatingWidgetView)1 ResourceProvider (com.android.systemui.plugins.ResourceProvider)1