fix(theme): Accidentally pushed this change

This commit is contained in:
Ahmad Ansori Palembani 2024-08-14 12:35:34 +07:00
parent 3202d8cdde
commit 9c29758a5d
Signed by: null2264
GPG key ID: BA64F8B60AF3EFB6

View file

@ -68,12 +68,10 @@ object ThemeUtil {
fun AppCompatActivity.setThemeByPref(preferences: PreferencesHelper) {
setTheme(getPrefTheme(preferences).styleRes)
if (preferences.nightMode().get() != AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM) {
val wic = WindowInsetsControllerCompat(window, window.decorView)
wic.isAppearanceLightStatusBars = !isDarkMode(preferences)
wic.isAppearanceLightNavigationBars = !isDarkMode(preferences)
}
}
fun AppCompatActivity.getThemeWithExtras(theme: Resources.Theme, preferences: PreferencesHelper, oldTheme: Resources.Theme?): Resources.Theme {
val useAmoled = isDarkMode(preferences) && preferences.themeDarkAmoled().get()