Tried changing the app language in Nougat using the following and failed.
config.setLocales(new LocaleList(locale));
getBaseContext().createConfigurationContext(config);
But its working with the below deprecated code
getBaseContext().getResources().updateConfiguration(config, getBaseContext().getResources().getDisplayMetrics());
Why so ? Am I doing anything wrong ?
My App supports both English UK & English US. System Language contains English India, English UK and some other languages also. App loads in English US itself, but my default language should be English UK if the system language is English India and the configuration is passed correctly as en_GB. Why is it so and not picking en_GB ?
Don't know where the responses I received went now. Its not showing.
The solution to have text translation in Nougat is well defined in this blog http://gunhansancar.com/change-language-programmatically-in-android/