Translucent Status Bar Bug

1.4k Views Asked by At

I have a problem with the translucent statusbar only when opening of the app for the first time. Take a look at the screenshot: enter image description here When opening the Navigation Drawer this bug appears, but only on first opening of the app. When I close my app and start it again, everything works fine.

Here is the XML of the Style I use which is including the translucent Status Bar:

<resources>

    <!-- Base application theme. -->
    <style name="TransTheme" parent="android:Theme.Holo.Light">
        <item name="android:windowBackground">@drawable/actionbar_background</item>
        <item name="android:windowTranslucentStatus">true</item>
        <item name="android:windowTranslucentNavigation">true</item>
        <item name="android:fitsSystemWindows">true</item>
        <item name="android:actionBarStyle">@style/ActionBar.GreenStyle</item>
    </style>

    <style name="ActionBar.GreenStyle" parent="@android:style/Widget.Holo.Light.ActionBar.Solid">
        <item name="android:background">@drawable/actionbar_background</item> 
    </style>

</resources>
1

There are 1 best solutions below

2
On

Add android:fitsSystemWindows="true" as attribute to the ListView of the drawer directly.