我正在使用谷歌地圖在我的活動。 當我在我的應用程序設置 中更改語言例如中文時,地圖的語言沒有改變,直到我重新打開我的應用程序。谷歌地圖緩存問題
Locale locale = new Locale(languageToLoad);
Locale.setDefault(locale);
Configuration config = new Configuration();
config.locale = locale;
getBaseContext().getResources().updateConfiguration(config,
getBaseContext().getResources().getDisplayMetrics());
setContentView(R.layout.activity_maps);
我搜索了很多關於這個問題,我發現它是谷歌地圖緩存問題,但沒有找到任何解決方案。
您是否嘗試過在onConfigurationChanged活動的方法來處理這個問題? – MatPag
我試過這個但不工作.....即使它不工作,以防萬一我重新打開活動......它只適用於應用程序重新打開。 – Manish