Enable customization of column count for application drawer

This commit is contained in:
Ensar Sarajčić
2023-07-13 12:19:33 +02:00
parent 552b7e561a
commit 7bbdf581de
9 changed files with 91 additions and 17 deletions

View File

@ -23,11 +23,11 @@ val Context.homeScreenGridItemsDB: HomeScreenGridItemsDao get() = AppsDatabase.g
val Context.hiddenIconsDB: HiddenIconsDao get() = AppsDatabase.getInstance(applicationContext).HiddenIconsDao()
fun Context.getColumnCount(): Int {
fun Context.getDrawerColumnCount(): Int {
return if (portrait) {
resources.getInteger(R.integer.portrait_column_count)
config.portraitDrawerColumnCount
} else {
resources.getInteger(R.integer.landscape_column_count)
config.landscapeDrawerColumnCount
}
}