Remove manual config item controlling to show input language settings
Change-Id: I77f831c653567f2cf214a5b61107b25cca6d751d
diff --git a/java/res/values-xlarge/config.xml b/java/res/values-xlarge/config.xml
index 80ef3cd..663332f 100644
--- a/java/res/values-xlarge/config.xml
+++ b/java/res/values-xlarge/config.xml
@@ -20,7 +20,6 @@
<resources>
<bool name="config_enable_show_settings_key_option">false</bool>
- <bool name="config_enable_show_subtype_settings">false</bool>
<bool name="config_enable_show_voice_key_option">false</bool>
<!-- TODO: This configuration value is temporary set true to check popup preview behavior. -->
<bool name="config_enable_show_popup_on_keypress_option">true</bool>
diff --git a/java/res/values/config.xml b/java/res/values/config.xml
index ad08049..c61a6d5 100644
--- a/java/res/values/config.xml
+++ b/java/res/values/config.xml
@@ -21,7 +21,6 @@
<resources>
<bool name="config_swipeDisambiguation">true</bool>
<bool name="config_enable_show_settings_key_option">true</bool>
- <bool name="config_enable_show_subtype_settings">true</bool>
<bool name="config_enable_show_voice_key_option">true</bool>
<bool name="config_enable_show_popup_on_keypress_option">true</bool>
<bool name="config_enable_show_recorrection_option">true</bool>
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java
index 18f7438..4db34c5 100644
--- a/java/src/com/android/inputmethod/latin/LatinIME.java
+++ b/java/src/com/android/inputmethod/latin/LatinIME.java
@@ -1007,14 +1007,14 @@
}
private void onSettingsKeyPressed() {
- if (!isShowingOptionDialog()) {
- if (!mSettingsValues.mEnableShowSubtypeSettings) {
- showSubtypeSelectorAndSettings();
- } else if (Utils.hasMultipleEnabledIMEsOrSubtypes(mImm)) {
- showOptionsMenu();
- } else {
- launchSettings();
- }
+ if (isShowingOptionDialog())
+ return;
+ if (InputMethodServiceCompatWrapper.CAN_HANDLE_ON_CURRENT_INPUT_METHOD_SUBTYPE_CHANGED) {
+ showSubtypeSelectorAndSettings();
+ } else if (Utils.hasMultipleEnabledIMEsOrSubtypes(mImm)) {
+ showOptionsMenu();
+ } else {
+ launchSettings();
}
}
diff --git a/java/src/com/android/inputmethod/latin/Settings.java b/java/src/com/android/inputmethod/latin/Settings.java
index d64410a..956c51e 100644
--- a/java/src/com/android/inputmethod/latin/Settings.java
+++ b/java/src/com/android/inputmethod/latin/Settings.java
@@ -87,7 +87,6 @@
public static class Values {
// From resources:
- public final boolean mEnableShowSubtypeSettings;
public final boolean mSwipeDownDismissKeyboardEnabled;
public final int mDelayBeforeFadeoutLanguageOnSpacebar;
public final int mDelayUpdateSuggestions;
@@ -128,8 +127,6 @@
}
// Get the resources
- mEnableShowSubtypeSettings = res.getBoolean(
- R.bool.config_enable_show_subtype_settings);
mSwipeDownDismissKeyboardEnabled = res.getBoolean(
R.bool.config_swipe_down_dismiss_keyboard_enabled);
mDelayBeforeFadeoutLanguageOnSpacebar = res.getInteger(
@@ -371,10 +368,7 @@
generalSettings.removePreference(findPreference(PREF_VIBRATE_ON));
}
- final boolean showSubtypeSettings = res.getBoolean(
- R.bool.config_enable_show_subtype_settings);
- if (InputMethodServiceCompatWrapper.CAN_HANDLE_ON_CURRENT_INPUT_METHOD_SUBTYPE_CHANGED
- && !showSubtypeSettings) {
+ if (InputMethodServiceCompatWrapper.CAN_HANDLE_ON_CURRENT_INPUT_METHOD_SUBTYPE_CHANGED) {
generalSettings.removePreference(findPreference(PREF_SUBTYPES));
}