I am having difficulties trying to remove the back/home button from the action bar.
getActionBar().setDisplayShowHomeEnabled(false); //disable back button getActionBar().setHomeButtonEnabled(false);
In a older android phone, the back button is removed with these two code lines. However with the nexus 4, the back button still appears but is just disabled. Also I am just adding a menu item on the right that behaves like the back/home button replacing the back/home button. What am I missing?
Use getActionBar().setDisplayHomeAsUpEnabled(false) to remove the home button from the action bar.
getActionBar().setDisplayHomeAsUpEnabled(false)
2.1m questions
2.1m answers
60 comments
57.0k users