Android Open Source - AndroidImageSlider Base Animation Interface






From Project

Back to project page AndroidImageSlider.

License

The source code is released under:

MIT License

If you think the Android project AndroidImageSlider listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package com.daimajia.slider.library.Animations;
//from   w  ww.  ja va  2s  .co m
import android.view.View;

/**
 * This interface gives you chance to inject your own animation or do something when the
 * {@link com.daimajia.slider.library.Tricks.ViewPagerEx} animation (PagerTransformer) starts or ends.
 *
 *
 * There are two items you have to know. The first item is the slider you are dragging. This item
 * I call it Current Item. The second is the slider that gonna to show. I call that Next Item.
 *
 * When you start to drag the slider in front of you, onPrepareCurrentItemLeaveScreen() and
 * onPrepareNextItemShowInScreen will be called.
 *
 * When you finish drag, the onCurrentItemDisappear and onNextItemAppear will be invoked.
 *
 * You can see a demo class {@link com.daimajia.slider.library.Animations.DescriptionAnimation},
 * this class gives the description text an animation.
 */
public interface BaseAnimationInterface {

    /**
     * When the current item prepare to start leaving the screen.
     * @param current
     */
    public void onPrepareCurrentItemLeaveScreen(View current);

    /**
     * The next item which will be shown in ViewPager/
     * @param next
     */
    public void onPrepareNextItemShowInScreen(View next);

    /**
     * Current item totally disappear from screen.
     * @param view
     */
    public void onCurrentItemDisappear(View view);

    /**
     * Next item totally show in screen.
     * @param view
     */
    public void onNextItemAppear(View view);
}




Java Source Code List

com.daimajia.slider.demo.ChildAnimationExample.java
com.daimajia.slider.demo.MainActivity.java
com.daimajia.slider.demo.TransformerAdapter.java
com.daimajia.slider.library.SliderAdapter.java
com.daimajia.slider.library.SliderLayout.java
com.daimajia.slider.library.Animations.BaseAnimationInterface.java
com.daimajia.slider.library.Animations.DescriptionAnimation.java
com.daimajia.slider.library.Indicators.PagerIndicator.java
com.daimajia.slider.library.SliderTypes.BaseSliderView.java
com.daimajia.slider.library.SliderTypes.DefaultSliderView.java
com.daimajia.slider.library.SliderTypes.TextSliderView.java
com.daimajia.slider.library.Transformers.AccordionTransformer.java
com.daimajia.slider.library.Transformers.BackgroundToForegroundTransformer.java
com.daimajia.slider.library.Transformers.BaseTransformer.java
com.daimajia.slider.library.Transformers.CubeInTransformer.java
com.daimajia.slider.library.Transformers.DefaultTransformer.java
com.daimajia.slider.library.Transformers.DepthPageTransformer.java
com.daimajia.slider.library.Transformers.FadeTransformer.java
com.daimajia.slider.library.Transformers.FlipHorizontalTransformer.java
com.daimajia.slider.library.Transformers.FlipPageViewTransformer.java
com.daimajia.slider.library.Transformers.ForegroundToBackgroundTransformer.java
com.daimajia.slider.library.Transformers.RotateDownTransformer.java
com.daimajia.slider.library.Transformers.RotateUpTransformer.java
com.daimajia.slider.library.Transformers.StackTransformer.java
com.daimajia.slider.library.Transformers.TabletTransformer.java
com.daimajia.slider.library.Transformers.ZoomInTransformer.java
com.daimajia.slider.library.Transformers.ZoomOutSlideTransformer.java
com.daimajia.slider.library.Transformers.ZoomOutTransformer.java
com.daimajia.slider.library.Tricks.FixedSpeedScroller.java
com.daimajia.slider.library.Tricks.InfinitePagerAdapter.java
com.daimajia.slider.library.Tricks.InfiniteViewPager.java
com.daimajia.slider.library.Tricks.ViewPagerEx.java