Android: get system default activity transition animations



android default activity animation (1)

You can override default animation with your own animation. So you can replace "open" transition to "close"

@Override
public void onBackPressed() {
    super.onBackPressed();
    overridePendingTransition(android.R.anim.fade_in, android.R.anim.fade_out);
}

https://ffff65535.com

Is there any way to get system default (vendor-specific) activity transitions? I need them to replace "open" transition to "close" so when I start a certain activity it would look like user is going back while the activity is actually starting.

I've already tried to do it using reflection but I didn't find these animations in classes com.android.internal.R$anim and android.R$anim even when they are referred from styles.xml in the SDK. Copying animation XML files from the SDK to my project is not an option because they are vendor-specific.





android-animation