#1176 - Fix invisible navigation bar icons on API 26

This commit is contained in:
Moez Bhatti
2018-06-17 14:59:38 -04:00
parent 126c959015
commit 1ce5846f76
@@ -73,8 +73,7 @@ abstract class QkThemedActivity : QkActivity() {
// When certain preferences change, we need to recreate the activity
Observable.merge(
listOf(prefs.night, prefs.black, prefs.textSize, prefs.systemFont)
.map { it.asObservable().skip(1) })
listOf(prefs.night, prefs.black, prefs.textSize, prefs.systemFont).map { it.asObservable().skip(1) })
.autoDisposable(scope())
.subscribe { recreate() }
@@ -89,7 +88,9 @@ abstract class QkThemedActivity : QkActivity() {
}
// Some devices don't let you modify android.R.attr.navigationBarColor
if (Build.VERSION.SDK_INT >= 27) window.navigationBarColor = resolveThemeColor(android.R.attr.windowBackground)
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
window.navigationBarColor = resolveThemeColor(android.R.attr.windowBackground)
}
// Set the color for the overflow and navigation icon
val textTertiary = resolveThemeColor(android.R.attr.textColorTertiary)