diff options
author | 2014-03-06 01:37:47 -0800 | |
---|---|---|
committer | 2014-03-06 01:37:47 -0800 | |
commit | 2f8258e3eafc5bbfbbb340865b3f3d71e2f86ca9 (patch) | |
tree | 3daf68f485b3acd885667597a755b24075aea830 /java/src/com/android/inputmethod/latin/LatinIME.java | |
parent | f845b8d576f96392b43eddc627b1a7e4ab3976d1 (diff) | |
parent | 3892991b80b1962454789f7233171620f70fb22b (diff) | |
download | latinime-2f8258e3eafc5bbfbbb340865b3f3d71e2f86ca9.tar.gz latinime-2f8258e3eafc5bbfbbb340865b3f3d71e2f86ca9.tar.xz latinime-2f8258e3eafc5bbfbbb340865b3f3d71e2f86ca9.zip |
am 3892991b: Merge "[IL124] Remove the KeyboardSwitcher arg to onCodeInput"
* commit '3892991b80b1962454789f7233171620f70fb22b':
[IL124] Remove the KeyboardSwitcher arg to onCodeInput
Diffstat (limited to 'java/src/com/android/inputmethod/latin/LatinIME.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/LatinIME.java | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java index 44353ba06..a9e548060 100644 --- a/java/src/com/android/inputmethod/latin/LatinIME.java +++ b/java/src/com/android/inputmethod/latin/LatinIME.java @@ -59,6 +59,7 @@ import com.android.inputmethod.accessibility.AccessibleKeyboardViewProxy; import com.android.inputmethod.annotations.UsedForTesting; import com.android.inputmethod.compat.InputMethodServiceCompatUtils; import com.android.inputmethod.dictionarypack.DictionaryPackConstants; +import com.android.inputmethod.event.InputTransaction; import com.android.inputmethod.keyboard.Keyboard; import com.android.inputmethod.keyboard.KeyboardActionListener; import com.android.inputmethod.keyboard.KeyboardId; @@ -1265,8 +1266,18 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen mSubtypeSwitcher.switchToShortcutIME(this); // Still call the *#onCodeInput methods for readability. } - mInputLogic.onCodeInput(codeToSend, keyX, keyY, mSettings.getCurrent(), mHandler, - mKeyboardSwitcher); + final InputTransaction completeInputTransaction = + mInputLogic.onCodeInput(mSettings.getCurrent(), codeToSend, keyX, keyY, + mKeyboardSwitcher.getKeyboardShiftMode(), mHandler); + switch (completeInputTransaction.getRequiredShiftUpdate()) { + case InputTransaction.SHIFT_UPDATE_LATER: + mHandler.postUpdateShiftState(); + break; + case InputTransaction.SHIFT_UPDATE_NOW: + mKeyboardSwitcher.updateShiftState(); + break; + default: // SHIFT_NO_UPDATE + } mKeyboardSwitcher.onCodeInput(codePoint); } |