Example usage for android.transition Slide setSlideEdge

List of usage examples for android.transition Slide setSlideEdge

Introduction

In this page you can find the example usage for android.transition Slide setSlideEdge.

Prototype

public void setSlideEdge(@GravityFlag int slideEdge) 

Source Link

Document

Change the edge that Views appear and disappear from.

Usage

From source file:org.huxizhijian.hhcomicviewer.ui.download.OfflineDownloadBaseActivity.java

@TargetApi(Build.VERSION_CODES.LOLLIPOP)
protected Visibility buildEnterTransition() {
    Slide enterTransition = new Slide();
    enterTransition.setDuration(getResources().getInteger(R.integer.anim_duration_medium));
    enterTransition.setSlideEdge(Gravity.RIGHT); //?
    return enterTransition;
}

From source file:appteam.nith.hillffair.activities.HomeActivity.java

private void setupWindowAnimations() {
    // Re-enter transition is executed when returning to this activity
    if (Build.VERSION.SDK_INT >= 21) {
        Slide slideTransition = new Slide();
        slideTransition.setSlideEdge(Gravity.LEFT);
        slideTransition.setDuration(800);
        getWindow().setReenterTransition(slideTransition);
        getWindow().setExitTransition(slideTransition);
    }/*  w  w  w . j a v  a2 s.  c  o  m*/

}