2016-11-19 9 views

답변

0

런타임에 자원 구성을 업데이트하여 응용 프로그램 언어를 변경할 수 있습니다. 이 코드처럼 :

Resources res=getResources(); 
    Configuration config = res.getConfiguration(); 
    Locale locale = new Locale("fr");//change to the France language 
    Locale.setDefault(locale); 
    config.locale = locale; 
    res.updateConfiguration(config, res.getDisplayMetrics()); 
+0

감사합니다. 귀하의 코드는 분명히 – aRaKaNoiD

+0

입니다. 그 질문은 아니 었습니다. 그러나'Locale current = getResources(). getConfiguration(). locale;'은 현재 로케일을 읽는데 사용될 수 있습니다. –