Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert to system default #41

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

tgvoskuilen
Copy link

I made the changes needed to get the locale-selection UI working and skip the screen updating. To see what the issue was you could try the updated example app without the library changes. Hope it's helpful!

toURButton.setOnClickListener { updateLocale(Locales.Urdu) }
language_picker.setOnCheckedChangeListener { _, checkedId ->
when(checkedId) {
R.id.language_default -> clearLocaleSelection()
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you change this to updateLocale(LocaleHelper.systemLocale) you can run this example app with the existing library to replicate the issues.

*/
fun hasLocaleSelection(context: Context): Boolean {
val prefs = getPreferences(context)
return prefs.contains(SELECTED_COUNTRY) && prefs.contains(SELECTED_COUNTRY)
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whoops, noticed the second one here should be SELECTED_LANGUAGE

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant