赞
踩
1. 修改开机默认语言:
(1).进入build/target/product目录,修改文件core.mk的PRODUCT_PROPERTY_OVERRIDES 值,例如,欲修改为默认中文,则增加
“\persist.sys.language=zh \ persist.sys.country=CN”
增加后的语句如PRODUCT_PROPERTY_OVERRIDES:= \
ro.config.notification_sound=OnTheHunt.ogg\
ro.config.alarm_alert=Alarm_Classic.ogg\ persist.sys.language=zh \ persist.sys.country=CN.
2. 屏蔽语言包:
进入frameworks\base\core\java\com\android\internal\app\LocalePicker.java
public staticList<LocaleInfo> getAllAssetLocales(Context context, booleanisInDeveloperMode) {
final Resources resources =context.getResources();
finalString[] locales = Resources.getSystem().getAssets().getLocales();
List<String> localeList = newArrayList<String>(locales.length);
Collections.addAll(localeList,locales);
// Don't show the pseudolocales unlesswe're in developer mode. http://b/17190407.
if (!isInDeveloperMode) {
localeList.remove("ar-XB");
localeList.remove("en-XA");
}
Collections.sort(localeList);
final String[] specialLocaleCodes =resources.getStringArray(R.array.special_locale_codes);
finalString[] specialLocaleNames = resources.getStringArray(R.array.special_locale_names);
找到这段函数很明显
final String[] locales =Resources.getSystem().getAssets().getLocales();
List<String> localeList= new ArrayList<String>(locales.length);
这段函数是调用语言包;
在下面一句函数下面屏蔽比如我们屏蔽英文
Collections.addAll(localeList, locales);
localeList.remove("en-US");
好了成功屏蔽掉英文了 重新make镜像烧写进去就没有英文语言选项了。希望可以帮到大家!
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。