The logic to determine when the suggestions strip (a.k.a. the
contextual strip) should be shown is already complex. In addition to
that the voice input key get shown on the strip as well. There are a
several factors to be considered and a few things to control.
- The password input field shouldn't have the strip.
- Show voice input key on the strip or not.
- User preference settings "Show Voice Input Key".
- A voice IME exists and is enabled.
- The input field may have a private IME option to prevent the voice
input key from being displayed.
- Application can specify auto completions.
- Full screen mode or not.
- User preference settings "Show correction suggestions".
- Always show, Show in portrait mode, Always hide.
- The input field may have flags to prevent showing suggestions or
auto corrections.
- Suggestions is empty or not.
- An important notice may be shown.
Bug: 14981852
Bug: 15436479
Change-Id: I3050fd53ee6271fc64a8f17b6b12d9581d37b750
This change also includes a fix that has suggestions re-computed
when the typed word is included but no prior suggestions were
found in spans.
Bug: 2349475
Change-Id: Ic06e6ac492507126ffc1e96a5f396c971b567272
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