Android APP获取系统当前语言代码

一、Android APP获取系统当前语言代码

            Locale locale = getResources().getConfiguration().locale;
            String language = locale.getLanguage();
            String local = Locale.getDefault().toString();
            String country =getResources().getConfiguration().locale.getCountry();

二、测试效果,设置成繁体hk。

猜你喜欢

转载自blog.csdn.net/qq_37858386/article/details/122965387
今日推荐