Example usage for android.view Window setReenterTransition

List of usage examples for android.view Window setReenterTransition

Introduction

In this page you can find the example usage for android.view Window setReenterTransition.

Prototype

public void setReenterTransition(Transition transition) 

Source Link

Document

Sets the Transition that will be used to move Views in to the scene when returning from a previously-started Activity.

Usage

From source file:com.fallahpoor.tehranbrt.MainActivity.java

private void setupWindowAnimation() {

    if (android.os.Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {

        Transition explodeTransition = TransitionInflater.from(this).inflateTransition(R.transition.explode);
        Window window = getWindow();

        window.setReenterTransition(explodeTransition);
        window.setExitTransition(explodeTransition);
        window.setAllowReturnTransitionOverlap(false);

    }//from ww w .j a v  a  2 s.com

}