remember if Use English was toggled
This commit is contained in:
parent
d55f99cad5
commit
e09709fd4e
2 changed files with 9 additions and 1 deletions
|
@ -96,5 +96,12 @@ open class BaseConfig(val context: Context) {
|
|||
|
||||
var useEnglish: Boolean
|
||||
get() = prefs.getBoolean(USE_ENGLISH, false)
|
||||
set(useEnglish) = prefs.edit().putBoolean(USE_ENGLISH, useEnglish).apply()
|
||||
set(useEnglish) {
|
||||
wasUseEnglishToggled = true
|
||||
prefs.edit().putBoolean(USE_ENGLISH, useEnglish).apply()
|
||||
}
|
||||
|
||||
var wasUseEnglishToggled: Boolean
|
||||
get() = prefs.getBoolean(WAS_USE_ENGLISH_TOGGLED, false)
|
||||
set(wasUseEnglishToggled) = prefs.edit().putBoolean(WAS_USE_ENGLISH_TOGGLED, wasUseEnglishToggled).apply()
|
||||
}
|
||||
|
|
|
@ -29,6 +29,7 @@ val APP_PASSWORD_HASH = "app_password_hash"
|
|||
val APP_PROTECTION_TYPE = "app_protection_type"
|
||||
val KEEP_LAST_MODIFIED = "keep_last_modified"
|
||||
val USE_ENGLISH = "use_english"
|
||||
val WAS_USE_ENGLISH_TOGGLED = "was_use_english_toggled"
|
||||
|
||||
// licenses
|
||||
val LICENSE_KOTLIN = 1
|
||||
|
|
Loading…
Reference in a new issue