I want to override the onBackPressed method on one of my activities. Currently my code looks like this:
public void onBackPressed(){
Intent i = new Intent(SubjectActivity.this, LevelActivity.class);
startActivity(i);
overridePendingTransition(0,0);
}
This gets rid of the default new page transition, but I want to use the default going back to the old page transition. Is there a way to override the onBackPressed activity without changing the transition, or else a built in way of using the default back transition?
If not, what code is needed to replicate this transition?