{"action":"created","issue":{"url":"https://api.github.com/repos/mikepenz/MaterialDrawer/issues/618","labels_url":"https://api.github.com/repos/mikepenz/MaterialDrawer/issues/618/labels{/name}","comments_url":"https://api.github.com/repos/mikepenz/MaterialDrawer/issues/618/comments","events_url":"https://api.github.com/repos/mikepenz/MaterialDrawer/issues/618/events","html_url":"https://github.com/mikepenz/MaterialDrawer/issues/618","id":104469197,"number":618,"title":"OnDrawerListener not working","user":{"login":"rams23","id":11600164,"avatar_url":"https://avatars.githubusercontent.com/u/11600164?v=3","gravatar_id":"","url":"https://api.github.com/users/rams23","html_url":"https://github.com/rams23","followers_url":"https://api.github.com/users/rams23/followers","following_url":"https://api.github.com/users/rams23/following{/other_user}","gists_url":"https://api.github.com/users/rams23/gists{/gist_id}","starred_url":"https://api.github.com/users/rams23/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rams23/subscriptions","organizations_url":"https://api.github.com/users/rams23/orgs","repos_url":"https://api.github.com/users/rams23/repos","events_url":"https://api.github.com/users/rams23/events{/privacy}","received_events_url":"https://api.github.com/users/rams23/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-09-02T12:27:29Z","updated_at":"2015-09-02T13:49:29Z","closed_at":null,"body":"Hi, sorry for question.\r\nI read another issue like this that was resolved but i still have the same problem.\r\nHere my code:\r\n```\r\nDrawerBuilder drawerBuilder = new DrawerBuilder();\r\n\r\n        drawerBuilder.withActivity(this)\r\n        .withToolbar(toolbar)\r\n                .withActionBarDrawerToggleAnimated(true)\r\n                .withActionBarDrawerToggle(true)\r\n        .withAccountHeader(headerResult)\r\n        .addDrawerItems(\r\n                new SectionDrawerItem().withName(\"Planning\"),\r\n                item1,\r\n                item2,\r\n                new DividerDrawerItem()\r\n        )\r\n        .withOnDrawerItemClickListener(new Drawer.OnDrawerItemClickListener() {\r\n            @Override\r\n            public boolean onItemClick(View view, int i, IDrawerItem iDrawerItem) {\r\n                Fragment fragment = null;\r\n                switch (iDrawerItem.getIdentifier()){\r\n                    case 1:\r\n                        fragment = new ExamsListFragment();\r\n                        break;\r\n                    case 2:\r\n                        fragment = new CalendarViewFragment();\r\n                        break;\r\n                }\r\n\r\n                final Fragment toCommit = fragment;\r\n\r\n                if (fragment!= null) {\r\n                    runnable = new Runnable() {\r\n                        @Override\r\n                        public void run() {\r\n                            getSupportFragmentManager().beginTransaction().replace(R.id.flContent, toCommit).commit();\r\n                        }\r\n                    };\r\n                    result.closeDrawer();\r\n\r\n                    return true;\r\n                }\r\n\r\n                runnable = null;\r\n                result.closeDrawer();\r\n                return false;\r\n            }\r\n        });\r\n\r\n\r\n        drawerBuilder.withOnDrawerListener(new Drawer.OnDrawerListener() {\r\n            @Override\r\n            public void onDrawerOpened(View view) {\r\n\r\n            }\r\n\r\n            @Override\r\n            public void onDrawerClosed(View view) {\r\n                if(runnable!= null){\r\n                    Handler handler = new Handler();\r\n                    handler.post(runnable);\r\n                    Toast.makeText(DrawerActivity.this, \"changing\",Toast.LENGTH_LONG).show();\r\n                }\r\n                Toast.makeText(DrawerActivity.this, \"not changing\",Toast.LENGTH_LONG).show();\r\n            }\r\n\r\n            @Override\r\n            public void onDrawerSlide(View view, float v) {\r\n\r\n            }\r\n        });\r\n\r\n        result = drawerBuilder.build();\r\n```\r\nThanks for your time."},"comment":{"url":"https://api.github.com/repos/mikepenz/MaterialDrawer/issues/comments/137088047","html_url":"https://github.com/mikepenz/MaterialDrawer/issues/618#issuecomment-137088047","issue_url":"https://api.github.com/repos/mikepenz/MaterialDrawer/issues/618","id":137088047,"user":{"login":"mikepenz","id":1476232,"avatar_url":"https://avatars.githubusercontent.com/u/1476232?v=3","gravatar_id":"","url":"https://api.github.com/users/mikepenz","html_url":"https://github.com/mikepenz","followers_url":"https://api.github.com/users/mikepenz/followers","following_url":"https://api.github.com/users/mikepenz/following{/other_user}","gists_url":"https://api.github.com/users/mikepenz/gists{/gist_id}","starred_url":"https://api.github.com/users/mikepenz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikepenz/subscriptions","organizations_url":"https://api.github.com/users/mikepenz/orgs","repos_url":"https://api.github.com/users/mikepenz/repos","events_url":"https://api.github.com/users/mikepenz/events{/privacy}","received_events_url":"https://api.github.com/users/mikepenz/received_events","type":"User","site_admin":false},"created_at":"2015-09-02T13:49:28Z","updated_at":"2015-09-02T13:49:28Z","body":"@rams23 what is not working. what do you expect?"}}