mirror of
https://github.com/null2264/yokai.git
synced 2025-06-21 10:44:42 +00:00
fix(theme): Status bar stays on dark mode when app is following system theme
Fixes GH-146
This commit is contained in:
parent
0bdecfe60f
commit
a8e8fe01b7
2 changed files with 4 additions and 2 deletions
|
@ -36,6 +36,8 @@
|
|||
- Fixed crashes when trying to reload extension repo due to connection issue
|
||||
- Fixed tap controls not working properly after zoom
|
||||
- Fixed (sorta, more like workaround) ANR issues when running background tasks, such as updating extensions
|
||||
- Fixed split (downloaded) tall images sometimes doesn't work
|
||||
- Fixed status bar stuck in dark mode when app is following system theme
|
||||
|
||||
## Translation
|
||||
- Update Japanese translation (akir45)
|
||||
|
|
|
@ -69,8 +69,8 @@ object ThemeUtil {
|
|||
fun AppCompatActivity.setThemeByPref(preferences: PreferencesHelper) {
|
||||
setTheme(getPrefTheme(preferences).styleRes)
|
||||
val wic = WindowInsetsControllerCompat(window, window.decorView)
|
||||
wic.isAppearanceLightStatusBars = preferences.nightMode().get() == AppCompatDelegate.MODE_NIGHT_NO
|
||||
wic.isAppearanceLightNavigationBars = preferences.nightMode().get() == AppCompatDelegate.MODE_NIGHT_NO
|
||||
wic.isAppearanceLightStatusBars = !isDarkMode(preferences)
|
||||
wic.isAppearanceLightNavigationBars = !isDarkMode(preferences)
|
||||
}
|
||||
|
||||
fun AppCompatActivity.getThemeWithExtras(theme: Resources.Theme, preferences: PreferencesHelper, oldTheme: Resources.Theme?): Resources.Theme {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue