The symptom : when text is selected and the device is rotated,
sometimes the keyboard sets the word as being composed around
the start of the selection. Upon the next rotation this ends up
with the keyboard committing some text in place of the selection.
The cause : another bug in the framework with rotation >.>
The keyboard receives a call to startInput with a wrong cursor
position, namely one that does not represent a selection. The
keyboard sets a composition according to this wrong data. When
the keyboard is rotated again, it commits the text, which takes
the place of the selection.
The solution : actually when restarting input the keyboard
realizes that the cursor position is wrong. We cancel composition
at that time.
For robustness, this change also implements two other defensive
changes : upon call to onUpdateSelection, we actually realize
that the previous values were wrong, so we also fix it at that
time, and in addition, when rotating, we finishComposingText()
instead of commitText() which is less dangerous. Implementing
this later change also allows us to let less internal variables
from InputLogic escape to LatinIME, so it's also a good change
for design.
Bug: 14140799
Change-Id: Ib10de18e53e376ac1bbc8487e13d969828483346
Rename `initialize' to `start' and `deactivate' to `stop' for ease
of understanding. It's completely bizarre that you can "deactivate"
a recapitalization and that will just restart a new one the next time
you press shift. Start and stop are easier to understand.
Change-Id: I455175aebfcfe11198c6c61bf2c6b19efc3f82df
This CL reorders keys around the spacebar.
- On phone's symbols and symbols shift layout, the comma key is moved
to the left of the spacebar to aligned with main layout.
- On tablet's layout, the comma key is moved to the left of the
spacebar on all layout to aligned with the same layout of
phone's. Also the comma key has "settings" as more keys.
- In Arabic and Perisan, the comma key of tablet already has some more keys
This CL remove "/" and add "settings" instead.
Bug: 15281451
Change-Id: I6e0e75e4d4abfb1f356e7499be91424c7c57c58b
Enrich the dictionary with many words generated from stems
extracted from the dictionary and rules written by hand.
This adds 45,619 words to the dictionary. Hopefully, almost none
of them is incorrect, though a lot are not very common.
Bug: 8010862
Change-Id: I51c7ebd16ff859ec1e765b0604dd1cfca159ab08
KeyboardAccessibilityDelegate.synthesizeTouchEvent() wrongly passed
pointer's id as a 6th argument of MotionEvent.obtain method that
should be metaState.
Change-Id: I822f9647a1ba27ee8cee39f373f6a1c003ebf665