Loading java/src/com/android/inputmethod/latin/LatinIME.java +1 −0 Original line number Diff line number Diff line Loading @@ -2429,6 +2429,7 @@ public final class LatinIME extends InputMethodService implements KeyboardAction // Hooks for hardware keyboard @Override public boolean onKeyDown(final int keyCode, final KeyEvent event) { if (!ProductionFlag.IS_HARDWARE_KEYBOARD_SUPPORTED) return super.onKeyDown(keyCode, event); // onHardwareKeyEvent, like onKeyDown returns true if it handled the event, false if // it doesn't know what to do with it and leave it to the application. For example, // hardware key events for adjusting the screen's brightness are passed as is. Loading java/src/com/android/inputmethod/latin/define/ProductionFlag.java +2 −0 Original line number Diff line number Diff line Loading @@ -28,4 +28,6 @@ public final class ProductionFlag { // be false, and any privacy controls should be enforced. IS_EXPERIMENTAL_DEBUG should be false // for any released build. public static final boolean IS_EXPERIMENTAL_DEBUG = false; public static final boolean IS_HARDWARE_KEYBOARD_SUPPORTED = true; } Loading
java/src/com/android/inputmethod/latin/LatinIME.java +1 −0 Original line number Diff line number Diff line Loading @@ -2429,6 +2429,7 @@ public final class LatinIME extends InputMethodService implements KeyboardAction // Hooks for hardware keyboard @Override public boolean onKeyDown(final int keyCode, final KeyEvent event) { if (!ProductionFlag.IS_HARDWARE_KEYBOARD_SUPPORTED) return super.onKeyDown(keyCode, event); // onHardwareKeyEvent, like onKeyDown returns true if it handled the event, false if // it doesn't know what to do with it and leave it to the application. For example, // hardware key events for adjusting the screen's brightness are passed as is. Loading
java/src/com/android/inputmethod/latin/define/ProductionFlag.java +2 −0 Original line number Diff line number Diff line Loading @@ -28,4 +28,6 @@ public final class ProductionFlag { // be false, and any privacy controls should be enforced. IS_EXPERIMENTAL_DEBUG should be false // for any released build. public static final boolean IS_EXPERIMENTAL_DEBUG = false; public static final boolean IS_HARDWARE_KEYBOARD_SUPPORTED = true; }