Skip to content
Commit 5959af13 authored by Yohei Yukawa's avatar Yohei Yukawa
Browse files

Introduce EditorInfo.IME_FLAG_NO_PERSONALIZED_LEARNING

In some situations it would be useful if the application can give a
hint that the user is not likely to want the IME to update
personalized data such as typing history and personalized language
model based on what the user typed the input area.

Typical use cases are:
 * When the application is in a special mode, where user's activities
   are expected to be not recorded in the application's history.
   Some web browsers and chat applications may have this kind of
   modes.
 * When storing typing history does not make much sense. Specifying
   this flag in typing games may help to avoid typing history from
   being filled up with words that the user is less likely to type
   in their daily life. Another example is that when the application
   already knows that the expected input is not a valid word (e.g.
   a promotion code that is not a valid word in any natural language).

Applications need to be aware that the flag is not a guarantee, and
some IMEs may not respect it.

Since this is basically about the general behavior that can be
combined with any of type of input types, this CL uses
EditorInfo.imeOptions instead of EditorInfo.inputType.

Also so far it look OK to do nothing in EditorInfo#makeCompatible()
regarding this flag because 1) this bit (0x1000000) has never been
used and 2) it is less likely that just passing that bit to an IME
that do not know about this bit causes any issue.

Bug: 28157942
Test: compile only as this is just a hint and OS does nothing
Change-Id: Ibf5ac3d2b8f39542baf2635c0cadbe242b059f81
parent d0bbe217
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment