Somebody know how to change the drawer icon on android 4.4.2? The other icons on desktop already have the option to change the icon or remove, but the drawer icon have not. Does anybody knows any app to change it?
1 Answers
If you are referring to the topmost left icon in the actionbar I was looking for the same look here for possible solution
In my case I have noticed that Eclipse generated the NavigationDrawerFragment class and that the drawer icon is set up by
mDrawerToggle = new ActionBarDrawerToggle(getActivity(), /* host Activity */
mDrawerLayout, /* DrawerLayout object */
R.drawable.ic_drawer, /* nav drawer image to replace 'Up' caret */
R.string.navigation_drawer_open, /*
* "open drawer" description for
* accessibility
*/
R.string.navigation_drawer_close /*
* "close drawer" description for
* accessibility
*/
)
As defined automatically by Eclipse I had android.support.v4.app.ActionBarDrawerToggle but this is deprecated and shall be android.support.v7.app.ActionBarDrawerToggle and the above shall change to
mDrawerToggle = new ActionBarDrawerToggle(getActivity(), /* host Activity */
mDrawerLayout, /* DrawerLayout object */
R.string.navigation_drawer_open, /*
* "open drawer" description for
* accessibility
*/
R.string.navigation_drawer_close /*
* "close drawer" description for
* accessibility
*/
)
and add more because I could not find a way to change the drawer icon with the v7.ActionBarDrawerTogle so I decided to hide it and show a custom home icon.
mDrawerToggle.setDrawerIndicatorEnabled(false);
mDrawerToggle.setHomeAsUpIndicator(yourdrawableres);
hth

- 1
- 1

- 392
- 5
- 13