ActionBar actionBar; actionBar=getActionBar(); actionBar.setDisplayHomeAsUpEnabled(true); @Override public boolean onOptionsItemSelected(MenuItem item) { switch (item.getItemId()) { case android.R.id.home: onBackPressed(); return true; } return super.onOptionsItemSelected(item); }
References
https://stackoverflow.com/questions/24032956/action-bar-back-button-not-working