I am implementing Toolbar along and Navigation drawer.I am customized my tool bar with my own views.I have my own menu(Hamburger) icon in my toolbar to open navigation drawer and I am showing badge count on my menu icon(Hamburger).So i would like to hide default Hamburger icon.
I have tried like this:
getSupportActionBar().setDisplayHomeAsUpEnabled(false);
getSupportActionBar().setDefaultDisplayHomeAsUpEnabled(false);
Please help me.Thanks in advance.
Make a menu xml This is going to be in res/menu/main_menu . Right click the res folder and choose New > Android Resource File. Type main_menu for the File name. Choose Menu for the Resource type.
In Android applications, Toolbar is a kind of ViewGroup that can be placed in the XML layouts of an activity. It was introduced by the Google Android team during the release of Android Lollipop(API 21). The Toolbar is basically the advanced successor of the ActionBar.
call .setDrawerIndicatorEnabled(false);
on your ActionBarDrawerToggle
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With