Update MainActivity.java

Added Method on onBackPressed