I am building application with navigation drawer. I want to add ic_drawer
icon to it. I am using this for it:
mDrawerToggle = new ActionBarDrawerToggle(
this, /* host Activity */
mDrawerLayout, /* DrawerLayout object */
R.drawable.ic_drawer, /* nav drawer icon to replace 'Up' caret */
R.string.drawer_open, /* "open drawer" description */
R.string.drawer_close /* "close drawer" description */
) { ... }
// Set the drawer toggle as the DrawerListener
mDrawerLayout.setDrawerListener(mDrawerToggle);
Actually, I got wrong icon and also I don't have animation on it. How I can fix it? I can't rly find anything, except drawable.ic_drawer
in my code.
Screens are below.
Blank screen screenshot.
Opened menu screen.
You can see on both images, that it is not ic_drawer
image. Actually, in IDEA, I see correct image.
Have you add
DrawerLayout
listener with yourActionBarDrawerToggle
? If not please add up these :