Example usage for android.transition Explode excludeTarget

List of usage examples for android.transition Explode excludeTarget

Introduction

In this page you can find the example usage for android.transition Explode excludeTarget.

Prototype

public Transition excludeTarget(int targetId, boolean exclude) 

Source Link

Document

Whether to add the given id to the list of target ids to exclude from this transition.

Usage

From source file:com.melkir.ourstreets.fragment.GalleryFragment.java

public GalleryFragment() {

    final Fade fade = new Fade();
    fade.addTarget(R.id.appbar);// w w w .  j  a v a  2 s .c  o m

    Explode explode = new Explode();
    explode.excludeTarget(R.id.appbar, true);

    Elevation elevation = new Elevation();
    elevation.addTarget(R.id.gallery_card);
    elevation.setStartDelay(250); // arbitrarily chosen delay

    TransitionSet exit = new TransitionSet();
    exit.addTransition(fade);
    exit.addTransition(explode);
    exit.addTransition(elevation);

    setExitTransition(exit);
}