我们手机中的谷歌地图应用程序显示了不同语言的英语版本。我想在我的应用程序中实现相同的功能。但我不能在android中做到这一点。你能不能请我帮忙摆脱它。
Set Google Map language as Locale language
https://developers.google.com/maps/documentation/javascript/basics?csw=1#Localization
https://developers.google.com/maps/documentation/javascript/localization
请检查此链接What is the list of supported languages/locales on Android?以获取支持的语言。 您只需在Splash中或在加载地图的位置更改应用程序的区域设置即可。
String languageToLoad = "ar";
Locale locale = new Locale(languageToLoad);
Locale.setDefault(locale);
Configuration config = new Configuration();
config.locale = locale;
getBaseContext().getResources().updateConfiguration(config,
getBaseContext().getResources().getDisplayMetrics());
希望这可以帮到你。