Update dropdown colors and list readability for SearchView.

Dismiss IME on launching suggestion.
This commit is contained in:
Amith Yamasani
2010-10-20 10:06:08 -07:00
parent 4f5f7c9683
commit b1818e83f4
8 changed files with 74 additions and 11 deletions

View File

@@ -1119,6 +1119,8 @@ public class ListPopupWindow {
public DropDownListView(Context context, boolean hijackFocus) {
super(context, null, com.android.internal.R.attr.dropDownListViewStyle);
mHijackFocus = hijackFocus;
// TODO: Add an API to control this
setCacheColorHint(0); // Transparent, since the background drawable could be anything.
}
/**

View File

@@ -717,6 +717,7 @@ public class SearchView extends LinearLayout {
if (mOnSuggestionListener == null
|| !mOnSuggestionListener.onSuggestionClicked(position)) {
launchSuggestion(position, KeyEvent.KEYCODE_UNKNOWN, null);
setImeVisibility(false);
dismissSuggestions();
}
}