Android examples for android.view.animation:Show Animation
show View with translation animation
import android.view.View; public class Main{ public static void show(View view) { if (view.getVisibility() == View.VISIBLE) return; view.setVisibility(View.VISIBLE); view.setAlpha(0f);//from ww w. jav a 2 s .c o m view.setTranslationY(view.getHeight() * 2f); view.animate().translationY(0f).alpha(1f).start(); } }