/frameworks/base/packages/SettingsProvider/res/values/defaults.xml
omron输入法:
<string name="default_input_method" translatable="false">jp.co.omronsoft.iwnnime.ml/.standardcommon.IWnnLanguageSwitcher</string>
搜狗输入法:com.sohu.inputmethod.sogou/.SogouIME
enabled_input_methods ==> 启用的输入方法列表
default_input_method???? ==> 默认输入法
1 <string name="enabled_input_methods" translatable="false">net.myself.inputmethod.swpinyin2/.SWIME:com.android.inputmethod.latin/.LatinIME</string> 2 <string name="default_input_method" translatable="false">net.sunniwell.inputmethod.swpinyin2/.SWIME</string>
?/frameworks/base/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java
DatabaseHelper.java的loadSecureSettings方法中加入:
?String systemcountrycode = SystemProperties.get("ro.product.countrycode");获取国家码 ? ? ? ? ? ? if ("JP".equals(systemcountrycode)) {日本地区则设置默认xx输入法 loadStringSetting(stmt, Settings.Secure.DEFAULT_INPUT_METHOD, R.string.default_input_method);
loadStringSetting(stmt, Settings.Secure.ENABLED_INPUT_METHODS, R.string.enabled_input_methods); ? ? ? ? ? ? }
adb shell settings get secure enabled_input_methods 获取所有输入法 jp.co.omronsoft.iwnnime.ml_lenovo/.standardcommon.IWnnLanguageSwitcher ?omron输入法 com.google.android.tts/com.google.android.apps.speech.tts.googletts.settings.asr.voiceime.VoiceInputMethodService com.google.android.googlequicksearchbox/com.google.android.voicesearch.ime.VoiceInputMethodService ?? com.google.android.inputmethod.latin/com.android.inputmethod.latin.LatinIME ? Gboard输入法
adb shell settings get secure default_input_method 获取默认输入法 com.google.android.inputmethod.latin/com.android.inputmethod.latin.LatinIME ? Gboard输入法
|