Set status bar color on API 27+ devices
This commit is contained in:
parent
61e50a9238
commit
5262f6f338
2 changed files with 21 additions and 1 deletions
20
app/ui/legacy/src/main/res/values-v27/themes.xml
Normal file
20
app/ui/legacy/src/main/res/values-v27/themes.xml
Normal file
|
@ -0,0 +1,20 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<style name="Theme.K9.Light" parent="Theme.K9.Light.Common">
|
||||
<item name="android:statusBarColor">@color/material_gray_100</item>
|
||||
<item name="android:windowLightStatusBar">true</item>
|
||||
|
||||
<item name="android:navigationBarColor">@color/material_gray_100</item>
|
||||
<item name="android:windowLightNavigationBar">true</item>
|
||||
</style>
|
||||
|
||||
<style name="Theme.K9.Dark" parent="Theme.K9.Dark.Common">
|
||||
<item name="android:statusBarColor">@color/material_gray_900</item>
|
||||
<item name="android:windowLightStatusBar">false</item>
|
||||
|
||||
<item name="android:navigationBarColor">@color/material_gray_900</item>
|
||||
<item name="android:windowLightNavigationBar">false</item>
|
||||
</style>
|
||||
|
||||
</resources>
|
|
@ -141,7 +141,7 @@ class ToolbarBottomSheetDialog internal constructor(context: Context, @StyleRes
|
|||
coordinator?.fitsSystemWindows = false
|
||||
|
||||
val flags = View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN or View.SYSTEM_UI_FLAG_LAYOUT_STABLE
|
||||
window.decorView.systemUiVisibility = flags
|
||||
window.decorView.systemUiVisibility = window.decorView.systemUiVisibility or flags
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue