Skip to content

Instantly share code, notes, and snippets.

@junf
Last active Jun 14, 2018
Embed
What would you like to do?
Restart Activity with no animation on Android.
private void restartThis() {
finish();
overridePendingTransition(0, 0);
startActivity(getIntent());
overridePendingTransition(0, 0);
}
@Muneesselvaraj171991
Copy link

Muneesselvaraj171991 commented Jun 14, 2018

finish();
overridePendingTransition(0, 0);
startActivity(getIntent());
overridePendingTransition(0, 0);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment