I'm having this issue with Google's NavigationDrawer not drawing correctly over the map when I pull it out from the side of the screen, it's being drawn under the map instead of over it, when closing it from already being open it is shown correctly.
The first picture is closing it, the second pic is opening it. This is occurring on a Galaxy S3 running 4.1 but on my Galaxy nexus 4.2 there's no issue. I had a similar issue with a ViewPager
and Map
a while ago that could be fixed by putting the map inside a FrameLayout
with another framelayout over it, but that was on pre-ICS devices. If I had to guess this has to do with hardware acceleration.
Here's a video of the bug in action on YouTube.
Just using DrawerLayout.bringChildToFront(View) didn't work for me, although I added a DrawerLayout.requestLayout() call and it did it!
Here's the code
ActionBarDrawerToggle drawerToggle = new ActionBarDrawerToggle(...) { @Override public void onDrawerSlide(View drawerView, float slideOffset) { super.onDrawerSlide(drawerView, slideOffset); drawerLayout.bringChildToFront(drawerView); drawerLayout.requestLayout(); } ... } drawerLayout.setDrawerListener(drawerToggle);
Hope this helps
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