Create fly out To Bottom Quick Animation with absolute value - Android Animation

Android examples for Animation:Alpha Fly Animation

Description

Create fly out To Bottom Quick Animation with absolute value

Demo Code


//package com.java2s;
import android.view.animation.AccelerateInterpolator;

import android.view.animation.Animation;

import android.view.animation.TranslateAnimation;

public class Main {
    public static Animation outToBottomQuickAnimation(
            final android.view.animation.Animation.AnimationListener animationlistener) {
        final TranslateAnimation translateanimation = new TranslateAnimation(
                2, 0F, 2, 0F, 2, 0F, 2, 1F);
        translateanimation.setDuration(300L);
        translateanimation.setInterpolator(new AccelerateInterpolator());
        translateanimation.setAnimationListener(animationlistener);
        return translateanimation;
    }/* w  ww  . ja va  2  s  .co m*/
}

Related Tutorials