THLfi / koronavilkku-android

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Device language preference list isn't strictly followed (A10)

mikahe opened this issue · comments

If you add Swedish (Finland) in device General settings and select that as default language, Koronavilkku/Coronablinkern changes language to Swedish. However, if you add 3rd language (English (Finland)) as priority 1, Swedish in priority 2 and Finnish in priority 3, app shows now Finnish.

Repro at least in Android 10, API 29, Samsung J6 SM-J600FN/DS
and Android 10, API 29 Samsung S9 SM-G960F

Actually I'm not sure if getting the language changing dynamically according to General settings also requires one time reinstalling the app when the new language is set as default.

Simply adding Swedish as a second language doesn't automatically change the app. (Honor P20Lite Android 9.1)

I'll have to look into this more, but my understanding is also that only the first language (priority 1) in device settings is used to localize the app? The current default language in koronavilkku is Finnish, so would get Finnish if your device is set to English. We'll have to investigate how we will set this up when adding English support.

It looks like Samsung's settings is showing Android 7 API 24 started improvements in localisation: https://developer.android.com/guide/topics/resources/multilingual-support where there are more than one choice of device language at a time

Ok, I think I've figured it out.. we are missing resConfigs in our gradle build file, so the priority list of device locales cannot be correctly applied. We'll check if fixing this would help pick up Swedish from priority 2.
Thanks for bringing this up!

This was a bit more complicated than just adding resConfigs, and should be fixed when we add English localization support

1.1.0 version with English support and an in-app language selector is now available and fixes this issue as well