Make insertSpaceOnPickSuggestionManually final.

Change-Id: I32fce0ea8c5c58b6f920d0758c8bf57769f39a12
This commit is contained in:
Jean Chalard 2011-12-16 13:05:43 +09:00
parent 4e8922f1be
commit ae0c109d11

View file

@ -798,28 +798,30 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
private void initializeInputAttributes(final EditorInfo editorInfo) { private void initializeInputAttributes(final EditorInfo editorInfo) {
mInputAttributes = new InputAttributes(editorInfo); mInputAttributes = new InputAttributes(editorInfo);
boolean insertSpaceOnPickSuggestionManually = false; final boolean insertSpaceOnPickSuggestionManually;
boolean inputTypeNoAutoCorrect = false; boolean inputTypeNoAutoCorrect = false;
boolean isSettingsSuggestionStripOn = false; boolean isSettingsSuggestionStripOn = false;
boolean applicationSpecifiedCompletionOn = false; boolean applicationSpecifiedCompletionOn = false;
if (editorInfo == null) if (editorInfo == null || editorInfo.inputType != InputType.TYPE_CLASS_TEXT) {
return; if (editorInfo.inputType == InputType.TYPE_NULL) {
final int inputType = editorInfo.inputType; // TODO: We should honor TYPE_NULL specification.
if (inputType == InputType.TYPE_NULL) { Log.i(TAG, "InputType.TYPE_NULL is specified");
// TODO: We should honor TYPE_NULL specification. }
Log.i(TAG, "InputType.TYPE_NULL is specified"); mApplicationSpecifiedCompletions = null;
} insertSpaceOnPickSuggestionManually = false;
final int inputClass = inputType & InputType.TYPE_MASK_CLASS; } else {
final int variation = inputType & InputType.TYPE_MASK_VARIATION; final int inputType = editorInfo.inputType;
if (inputClass == 0) { final int inputClass = inputType & InputType.TYPE_MASK_CLASS;
Log.w(TAG, String.format("Unexpected input class: inputType=0x%08x imeOptions=0x%08x", final int variation = inputType & InputType.TYPE_MASK_VARIATION;
inputType, editorInfo.imeOptions)); if (inputClass == 0) {
} Log.w(TAG, String.format("Unexpected input class: inputType=0x%08x"
+ " imeOptions=0x%08x",
inputType, editorInfo.imeOptions));
}
mApplicationSpecifiedCompletions = null; mApplicationSpecifiedCompletions = null;
if (inputClass == InputType.TYPE_CLASS_TEXT) {
isSettingsSuggestionStripOn = true; isSettingsSuggestionStripOn = true;
// Make sure that passwords are not displayed in {@link SuggestionsView}. // Make sure that passwords are not displayed in {@link SuggestionsView}.
if (InputTypeCompatUtils.isPasswordInputType(inputType) if (InputTypeCompatUtils.isPasswordInputType(inputType)