Home » Android » Android Lollipop navigation bar overlays activity view

Android Lollipop navigation bar overlays activity view

Posted by: admin June 15, 2020 Leave a comment


the navigation bar is overlaying my activity view on the bottom. Same issue like here: Android Navigation Bar overlaying my view

The issue seems to happen only on Android Lollipop. On my Moto G with KitKat 4.4.4. i don’t have this issue. I don’t know why this problem is only related to Lollipop.

My problem is, with the solution @ps-glass postet is not working for me somehow setting fitsSystemWindow = true. I tried it with the theme or with the layout file directly, nothing worked for me so far.

Here is an image: https://drive.google.com/file/d/0B5g_MttTC7ZIQzNfS3Y2dVFKSFk/view?usp=sharing

You can only see a bit of the text, the rest is overlaid by the navigation bar.

How to&Answers:

I found out that this problem is related to a library we are using:
and other people have this problem too after they updated their AppCompat to v21.

Some solutions were posted here https://github.com/jfeinstein10/SlidingMenu/issues/680 and another one here The getDecorView method return view include navigation bar view on lollipop?

The Solution from https://stackoverflow.com/users/715451/saulobrito is working for me now and it is the easiest way i think.

<style name="Theme" parent="FrameworkRoot.Theme">
    <item name="android:windowDrawsSystemBarBackgrounds">false</item>

I put this code snippet to a my theme in the res/values-v21 folder.