Skip to content

Backport of Transitions API for animations from Android KitKat and Lollipop. Compatible with Android 2.2+

License

Notifications You must be signed in to change notification settings

Avinash-Bhat/transitions-everywhere

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

85 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Transitions Everywhere

Backport of Transitions API from Android KitKat and Lollipop. Compatible with Android 2.2+.

About Transitions API

Video - DevBytes: Android 4.4 Transitions
Sample project from Google

Changelog

1.3.1 - Bug fix
1.3.0 - Merge with changes from Android 5.1 and some major bug fixes
1.2.0 - 1.2.2 - Bug fix
1.1.0 - Port of new transitions from Android 5.0 Lollipop

Simple example

Usage

Gradle:

dependencies {
    compile "com.github.andkulikov:transitions-everywhere:1.3.1"
}

Use transition classes from package android.transitions.everywhere.* instead of android.transition.* from android framework Transitions API.

Transitions via XML

If you use XML files to create your transitions you need to put them in the res/anim folder instead of the res/transition folder. You need to use application attributes namespase instead of android:. For example:

<transitionSet xmlns:app="http://schemas.android.com/apk/res-auto"
               app:duration="400">
    <changeBounds/>
    <fade app:fadingMode="fade_in">
        <targets>
            <target app:targetId="@id/transition_title"/>
        </targets>
    </fade>
</transitionSet>

Transition names of views

Android 5.0 adds new method setTransitionName() for View class. With this library you should call TransitionManager.setTransitionName(View v, String transitionName) method instead to provide backward compatibility.

About library

Transition animations backported to Android 3.0.
For Android ver. >= 2.2 and < 3.0 scene to scene (layout to layout) changes is executed by the same API but without animations.

Note: some of transitions classes was marked as hidden by developers of Android. You can find it in package android.transitions.everywhere.hidden. But i don't recommend to use them because they can work unstable.

Thanks to github users: pardom and guerwan


[![Android Arsenal](https://img.shields.io/badge/Android%20Arsenal-transitions--everywhere-brightgreen.svg?style=flat)](https://android-arsenal.com/details/1/1050)

About

Backport of Transitions API for animations from Android KitKat and Lollipop. Compatible with Android 2.2+

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 100.0%