Show physical keyboard settings even when IME is enabled.
The WindowManager lies about the configuration in order to get the IME to show but the Settings page should still show the physical keyboard options if one is connected though, so remove the configuration check and just always check to see if there's a full keyboard connected. Bug: 14066881 Change-Id: I085fe4160f3524f3c95737a6809ee03fec5230b4
This commit is contained in:
@@ -564,7 +564,6 @@ public class InputMethodAndLanguageSettings extends SettingsPreferenceFragment
|
||||
|
||||
private void updateHardKeyboards() {
|
||||
mHardKeyboardPreferenceList.clear();
|
||||
if (getResources().getConfiguration().keyboard == Configuration.KEYBOARD_QWERTY) {
|
||||
final int[] devices = InputDevice.getDeviceIds();
|
||||
for (int i = 0; i < devices.length; i++) {
|
||||
InputDevice device = InputDevice.getDevice(devices[i]);
|
||||
@@ -594,7 +593,6 @@ public class InputMethodAndLanguageSettings extends SettingsPreferenceFragment
|
||||
mHardKeyboardPreferenceList.add(pref);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!mHardKeyboardPreferenceList.isEmpty()) {
|
||||
for (int i = mHardKeyboardCategory.getPreferenceCount(); i-- > 0; ) {
|
||||
@@ -795,7 +793,6 @@ public class InputMethodAndLanguageSettings extends SettingsPreferenceFragment
|
||||
// Hard keyboards
|
||||
InputManager inputManager = (InputManager) context.getSystemService(
|
||||
Context.INPUT_SERVICE);
|
||||
if (resources.getConfiguration().keyboard == Configuration.KEYBOARD_QWERTY) {
|
||||
boolean hasHardKeyboards = false;
|
||||
|
||||
final int[] devices = InputDevice.getDeviceIds();
|
||||
@@ -865,7 +862,6 @@ public class InputMethodAndLanguageSettings extends SettingsPreferenceFragment
|
||||
indexable.screenTitle = screenTitle;
|
||||
indexables.add(indexable);
|
||||
}
|
||||
}
|
||||
|
||||
// Voice recognizers.
|
||||
List<ResolveInfo> recognizers = context.getPackageManager()
|
||||
|
Reference in New Issue
Block a user