to Big Animation with ScaleAnimation - Android android.view.animation

Android examples for android.view.animation:Scale Animation

Description

to Big Animation with ScaleAnimation

Demo Code

import android.view.View;
import android.view.animation.Animation;
import android.view.animation.ScaleAnimation;

public class Main {

  public static void toBigAnim(View view) {
    ScaleAnimation animation = new ScaleAnimation(0.0f, 1.0f, 0.0f, 1.0f, Animation.RELATIVE_TO_SELF, 0.5f,
        Animation.RELATIVE_TO_SELF, 0.0f);
    animation.setDuration(1000);/*from w w  w. jav  a2s.  c  o m*/
    animation.setFillAfter(true);
    view.setAnimation(animation);
    animation.start();
    view.setVisibility(View.VISIBLE);
  }

}

Related Tutorials