mirror of
https://github.com/mihonapp/mihon.git
synced 2025-10-30 05:47:57 +01:00
Use 1.x preference abstraction (#8020)
* Use 1.x preference abstraction - Uses SharedPreferences compared to 1.x impl which uses DataStore but it breaks all settings screens currently - Move PreferencesHelper to new PreferenceStore - PreferencesHelper should be split into smaller preference stores and be in core or domain - Remove flow preferences as new PreferenceStore handles changes for us Co-authored-by: inorichi <3521738+inorichi@users.noreply.github.com> * Fix PreferenceMutableState not updating * Fix changes not emitting on first subscription Co-authored-by: inorichi <3521738+inorichi@users.noreply.github.com>
This commit is contained in:
@@ -193,7 +193,7 @@ class ExtensionManager(
|
||||
.map(AvailableSources::lang)
|
||||
|
||||
val deviceLanguage = Locale.getDefault().language
|
||||
val defaultLanguages = preferences.enabledLanguages().defaultValue
|
||||
val defaultLanguages = preferences.enabledLanguages().defaultValue()
|
||||
val languagesToEnable = availableLanguages.filter {
|
||||
it != deviceLanguage && it.startsWith(deviceLanguage)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user