Android examples for Animation:Rotate Animation
rotate In Animation
//package com.java2s; import android.view.animation.RotateAnimation; import android.widget.RelativeLayout; public class Main { public static void rotateInAnimation(RelativeLayout level) { rotateInAnimation(level, 0);//w w w. j a va2 s . c o m } public static void rotateInAnimation(RelativeLayout level, long i) { RotateAnimation animation = new RotateAnimation(180, 360, level.getWidth() / 2, level.getHeight()); animation.setFillAfter(true); animation.setDuration(500); animation.setStartOffset(i); level.startAnimation(animation); } }