获取系统语言
Locale locale = getResources().getConfiguration().locale;
Log.d("wangrui",locale.getLanguage());
这段代码演示了如何在Android中通过Resources和Configuration获取当前系统的语言。Log.d()函数用于打印所获取的语言代码。
获取系统语言
Locale locale = getResources().getConfiguration().locale;
Log.d("wangrui",locale.getLanguage());

被折叠的 条评论
为什么被折叠?