Remove en-GB option since we don't actually localize different English locales
This commit is contained in:
parent
0eadc028b6
commit
0cb042cd93
6 changed files with 10 additions and 6 deletions
|
@ -30,7 +30,7 @@ android {
|
||||||
minSdkVersion(AndroidConfig.minSdk)
|
minSdkVersion(AndroidConfig.minSdk)
|
||||||
targetSdkVersion(AndroidConfig.targetSdk)
|
targetSdkVersion(AndroidConfig.targetSdk)
|
||||||
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
||||||
versionCode = 64
|
versionCode = 65
|
||||||
versionName = "0.11.1"
|
versionName = "0.11.1"
|
||||||
|
|
||||||
buildConfigField("String", "COMMIT_COUNT", "\"${getCommitCount()}\"")
|
buildConfigField("String", "COMMIT_COUNT", "\"${getCommitCount()}\"")
|
||||||
|
|
|
@ -232,6 +232,11 @@ object Migrations {
|
||||||
putString(PreferenceKeys.librarySortingDirection, newSortingDirection.name)
|
putString(PreferenceKeys.librarySortingDirection, newSortingDirection.name)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (oldVersion < 65) {
|
||||||
|
if (preferences.lang().get() in listOf("en-US", "en-GB")) {
|
||||||
|
preferences.lang().set("en")
|
||||||
|
}
|
||||||
|
}
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -282,7 +282,7 @@ class PreferencesHelper(val context: Context) {
|
||||||
fun downloadNewCategories() = flowPrefs.getStringSet(Keys.downloadNewCategories, emptySet())
|
fun downloadNewCategories() = flowPrefs.getStringSet(Keys.downloadNewCategories, emptySet())
|
||||||
fun downloadNewCategoriesExclude() = flowPrefs.getStringSet(Keys.downloadNewCategoriesExclude, emptySet())
|
fun downloadNewCategoriesExclude() = flowPrefs.getStringSet(Keys.downloadNewCategoriesExclude, emptySet())
|
||||||
|
|
||||||
fun lang() = prefs.getString(Keys.lang, "")
|
fun lang() = flowPrefs.getString(Keys.lang, "")
|
||||||
|
|
||||||
fun defaultCategory() = prefs.getInt(Keys.defaultCategory, -1)
|
fun defaultCategory() = prefs.getInt(Keys.defaultCategory, -1)
|
||||||
|
|
||||||
|
|
|
@ -128,7 +128,7 @@ class LibraryItem(
|
||||||
val tag = if (minus) { query.substringAfter("-") } else query
|
val tag = if (minus) { query.substringAfter("-") } else query
|
||||||
return when (sourceName.contains(tag, true)) {
|
return when (sourceName.contains(tag, true)) {
|
||||||
false -> containsGenre(query, genres)
|
false -> containsGenre(query, genres)
|
||||||
else -> !minus
|
else -> !minus
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -176,8 +176,7 @@ class SettingsGeneralController : SettingsController() {
|
||||||
"eo",
|
"eo",
|
||||||
"es",
|
"es",
|
||||||
"es-419",
|
"es-419",
|
||||||
"en-US",
|
"en",
|
||||||
"en-GB",
|
|
||||||
"fa",
|
"fa",
|
||||||
"fi",
|
"fi",
|
||||||
"fil",
|
"fil",
|
||||||
|
|
|
@ -25,7 +25,7 @@ object LocaleHelper {
|
||||||
/**
|
/**
|
||||||
* The application's locale. When it's null, the system locale is used.
|
* The application's locale. When it's null, the system locale is used.
|
||||||
*/
|
*/
|
||||||
private var appLocale = getLocaleFromString(preferences.lang())
|
private var appLocale = getLocaleFromString(preferences.lang().get())
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The currently applied locale. Used to avoid losing the selected language after a non locale
|
* The currently applied locale. Used to avoid losing the selected language after a non locale
|
||||||
|
|
Reference in a new issue