am 8bd65855: Merge "Revert "Fix a race condition.""
* commit '8bd658555d739ad0cb30a0805f2ec087a8a6930e': Revert "Fix a race condition."main
commit
356206178a
|
@ -1113,11 +1113,8 @@ public final class InputLogic {
|
|||
keyboardSwitcher.getKeyboard());
|
||||
mWordComposer.setCursorPositionWithinWord(
|
||||
typedWord.codePointCount(0, numberOfCharsInWordBeforeCursor));
|
||||
// TODO: Change these two lines to setComposingRegion(cursorPosition,
|
||||
// cursorPosition + range.getNumberOfCharsInWordAfterCursor());
|
||||
mConnection.deleteSurroundingText(numberOfCharsInWordBeforeCursor,
|
||||
typedWord.length() - numberOfCharsInWordBeforeCursor);
|
||||
mConnection.setComposingText(typedWord, 1);
|
||||
mConnection.setComposingRegion(expectedCursorPosition - numberOfCharsInWordBeforeCursor,
|
||||
expectedCursorPosition + range.getNumberOfCharsInWordAfterCursor());
|
||||
if (suggestions.isEmpty()) {
|
||||
// We come here if there weren't any suggestion spans on this word. We will try to
|
||||
// compute suggestions for it instead.
|
||||
|
|
Loading…
Reference in New Issue