Simple Override onBackPressed Method:
@Override
public void onBackPressed() {
super.onBackPressed();
this.finish();
}
More Related Contents:
- Button a button unclickabale in Android
- Add button to a layout programmatically
- How to open the options menu programmatically?
- How to handle Back button with in the dialog?
- How to prevent the activity from loading twice on pressing the button
- Prevent Activity Stack from being Restored?
- How to change the activity background from fragment inside it [closed]
- Start and Close single Activity from BroadcastReceiver
- Start Activity from Service in Android
- How to have Android Service communicate with Activity
- Change application’s starting activity
- Why fragments, and when to use fragments instead of activities?
- Calling startActivity() from outside of an Activity context
- How to open a second activity on click of button in android app
- How to show a dialog to confirm that the user wishes to exit an Android Activity?
- Best way to add Activity to an Android project in Eclipse?
- How do you check the internet connection in android? [duplicate]
- Android: how to make an activity return results to the activity which calls it?
- How to create custom shape button with selector in android?
- Make new activity appear behind old one during transition
- Single click and double click of a button in android
- Start new Activity and finish current one in Android? [duplicate]
- onActivityResult do not fire if launch mode of activity is singleInstance
- Alternative to “FLAG_BLUR_BEHIND” in Android?
- Start Activity screen even if screen is locked in Android
- OnCreateView called multiple times / Working with ActionBar and Fragments
- Can i automatically send SMS (Without the user need to approve)
- How to have activity in Android with a close button at the top corner?
- What method is being called when I close an app
- Can you have two activities running at the same time?