List of usage examples for android.view.animation DecelerateInterpolator DecelerateInterpolator
public DecelerateInterpolator()
From source file:Main.java
public static DecelerateInterpolator getDecelerateInterpolator() { return new DecelerateInterpolator(); }
From source file:Main.java
public static void alpha(View view, float alpha, int duration, int startDelay) { view.animate().alpha(alpha).setInterpolator(new DecelerateInterpolator()).setDuration(duration) .setStartDelay(startDelay);//from w w w. ja v a2 s . c o m }
From source file:Main.java
public static Animation getFadeInAnimation(int duration) { Animation fadeIn = new AlphaAnimation(0, 1); fadeIn.setInterpolator(new DecelerateInterpolator()); //add this fadeIn.setDuration(duration);//from w w w .j a va 2s. c om return fadeIn; }
From source file:Main.java
public static void translationYBy(View view, int distance, int duration, int startDelay) { view.animate().translationYBy(distance).setDuration(duration).setStartDelay(startDelay) .setInterpolator(new DecelerateInterpolator()); }
From source file:Main.java
public static void translationX(View view, int translationX, int duration, int startDelay) { view.animate().translationX(translationX).setDuration(duration) .setInterpolator(new DecelerateInterpolator()).setStartDelay(startDelay); }
From source file:Main.java
public static Animation createAlpha(float fromAlpha, float toAlpha, long duration) { Animation animation = new AlphaAnimation(fromAlpha, toAlpha); animation.setInterpolator(new DecelerateInterpolator()); animation.setDuration(duration);//from w ww . j a v a 2s . com return animation; }
From source file:Main.java
public static void fadeIn(View view, int durationMillis) { if (view != null) { AlphaAnimation fadeImage = new AlphaAnimation(0, 1); fadeImage.setDuration(durationMillis); fadeImage.setInterpolator(new DecelerateInterpolator()); view.startAnimation(fadeImage);/* ww w. jav a 2 s . c om*/ } }
From source file:Main.java
public static void rotation(View view, float rotation, int duration, int startDelay, Animator.AnimatorListener listener) { view.animate().rotation(rotation).setDuration(duration).setStartDelay(startDelay) .setInterpolator(new DecelerateInterpolator()).setListener(listener); }
From source file:Main.java
public static Animation fadeIn() { Animation fadein = new AlphaAnimation(0.0f, +1.0f); fadein.setDuration(DURATION);//from w w w . j a v a 2s .co m fadein.setInterpolator(new DecelerateInterpolator()); // start quickly... return fadein; }
From source file:Main.java
public static Animation getScaleAnimation_see_all() { Animation animation = new ScaleAnimation(1.0f, 1.0f, 0.0f, 1.0f, Animation.RELATIVE_TO_SELF, 0f, Animation.RELATIVE_TO_SELF, 0f); animation.setInterpolator(new DecelerateInterpolator()); animation.setDuration(200);/*from w ww . j a v a 2 s .c o m*/ return animation; }