aboutsummaryrefslogtreecommitdiffstats
path: root/java/src/com/android/inputmethod/latin/LatinIME.java
diff options
context:
space:
mode:
authorTadashi G. Takaoka <takaoka@google.com>2014-05-24 02:28:00 +0900
committerTadashi G. Takaoka <takaoka@google.com>2014-05-26 14:11:41 +0900
commit9df51d10fa6b5b21de564cd93926a88690a98600 (patch)
treee23358ae3b457421868e9727bedc84f5502b0d05 /java/src/com/android/inputmethod/latin/LatinIME.java
parent4905d83270720ce9b9121595277dae6ba8102f16 (diff)
downloadlatinime-9df51d10fa6b5b21de564cd93926a88690a98600.tar.gz
latinime-9df51d10fa6b5b21de564cd93926a88690a98600.tar.xz
latinime-9df51d10fa6b5b21de564cd93926a88690a98600.zip
Keep showing important notice when "show correction suggestions" is off
When 1. The important notice message is shown on the suggestions strip. 2. And the "Show correction suggestions" settings is off. we will keep showing the important notice message on the suggestion strip. Bug: 13741460 Change-Id: I411007ab1e5e6959b6cdba7a6601a84635259313
Diffstat (limited to 'java/src/com/android/inputmethod/latin/LatinIME.java')
-rw-r--r--java/src/com/android/inputmethod/latin/LatinIME.java15
1 files changed, 11 insertions, 4 deletions
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java
index 1e1d10931..aeae6aab4 100644
--- a/java/src/com/android/inputmethod/latin/LatinIME.java
+++ b/java/src/com/android/inputmethod/latin/LatinIME.java
@@ -258,7 +258,8 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
if (latinIme == null) {
return;
}
- if (!latinIme.mSettings.getCurrent().isSuggestionStripVisible()) {
+ if (!latinIme.mSettings.getCurrent()
+ .isCurrentOrientationAllowingSuggestionsPerUserSettings()) {
return;
}
removeMessages(MSG_RESUME_SUGGESTIONS);
@@ -1346,7 +1347,7 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
currentSettings.mInputAttributes)) {
return true;
}
- if (!currentSettings.isSuggestionStripVisible()) {
+ if (!currentSettings.isCurrentOrientationAllowingSuggestionsPerUserSettings()) {
return false;
}
if (currentSettings.isApplicationSpecifiedCompletionsOn()) {
@@ -1391,8 +1392,14 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
final SettingsValues currentSettings = mSettings.getCurrent();
final boolean showSuggestions;
- if (SuggestedWords.EMPTY == suggestedWords || suggestedWords.isPunctuationSuggestions()
- || !currentSettings.isSuggestionsRequested()) {
+ // May show the important notice when there are no suggestions to show,
+ if (SuggestedWords.EMPTY == suggestedWords
+ // or the suggestion strip is expected to show punctuation suggestions,
+ || suggestedWords.isPunctuationSuggestions()
+ // or it's not requested to show suggestions by the input field,
+ || !currentSettings.isSuggestionsRequested()
+ // or the "show correction suggestions" settings is off by users preference.
+ || !currentSettings.isCurrentOrientationAllowingSuggestionsPerUserSettings()) {
showSuggestions = !mSuggestionStripView.maybeShowImportantNoticeTitle(
currentSettings.mInputAttributes);
} else {