am 69609ed4: Merge "Do not run the spell checker in SearchView" into jb-dev

* commit '69609ed40260b67d5ee6baace9d60cf9b677f4c9':
  Do not run the spell checker in SearchView
This commit is contained in:
Satoshi Kataoka
2012-06-04 22:44:58 -07:00
committed by Android Git Automerger

View File

@@ -1091,6 +1091,13 @@ public class SearchView extends LinearLayout implements CollapsibleActionView {
inputType &= ~InputType.TYPE_TEXT_FLAG_AUTO_COMPLETE;
if (mSearchable.getSuggestAuthority() != null) {
inputType |= InputType.TYPE_TEXT_FLAG_AUTO_COMPLETE;
// TYPE_TEXT_FLAG_AUTO_COMPLETE means that the text editor is performing
// auto-completion based on its own semantics, which it will present to the user
// as they type. This generally means that the input method should not show its
// own candidates, and the spell checker should not be in action. The text editor
// supplies its candidates by calling InputMethodManager.displayCompletions(),
// which in turn will call InputMethodSession.displayCompletions().
inputType |= InputType.TYPE_TEXT_FLAG_NO_SUGGESTIONS;
}
}
mQueryTextView.setInputType(inputType);