By default, Android OS call onBaskPressed()
when the back button is pressed and call finish()
for the current activity.
Then, the system automatically redirects you to the previous Activity (only if you didn't call finish()
in the previous one). So, you don't need to override this method because the OS does it for you.
If press the hardware back button on your emulator doesn't do anything, edit the emulator and make sure that you enable the Hardware keyboard present by checking it. Also, don't use No skin.