Merge "Fix a bug where moving the cursor would not reset selection"
This commit is contained in:
commit
6b64a0fedc
1 changed files with 7 additions and 7 deletions
|
@ -895,20 +895,16 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
|
|||
}
|
||||
mComposingStringBuilder.setLength(0);
|
||||
mHasUncommittedTypedChars = false;
|
||||
if (isCursorTouchingWord()) {
|
||||
mHandler.cancelUpdateBigramPredictions();
|
||||
mHandler.postUpdateSuggestions();
|
||||
} else {
|
||||
setPunctuationSuggestions();
|
||||
}
|
||||
TextEntryState.reset();
|
||||
updateSuggestions();
|
||||
final InputConnection ic = getCurrentInputConnection();
|
||||
if (ic != null) {
|
||||
ic.finishComposingText();
|
||||
}
|
||||
mVoiceProxy.setVoiceInputHighlighted(false);
|
||||
} else if (!mHasUncommittedTypedChars && TextEntryState.isAcceptedDefault()) {
|
||||
} else if (!mHasUncommittedTypedChars) {
|
||||
TextEntryState.reset();
|
||||
updateSuggestions();
|
||||
}
|
||||
mJustAddedMagicSpace = false; // The user moved the cursor.
|
||||
mJustReplacedDoubleSpace = false;
|
||||
|
@ -1654,6 +1650,10 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
|
|||
return;
|
||||
}
|
||||
|
||||
mHandler.cancelUpdateSuggestions();
|
||||
mHandler.cancelUpdateOldSuggestions();
|
||||
mHandler.cancelUpdateBigramPredictions();
|
||||
|
||||
if (!mHasUncommittedTypedChars) {
|
||||
setPunctuationSuggestions();
|
||||
return;
|
||||
|
|
Loading…
Reference in a new issue