From 5eafe7264c78ce298cba9e12896382a22c714f7e Mon Sep 17 00:00:00 2001 From: Mindy Pereira Date: Wed, 17 Aug 2011 10:37:59 -0700 Subject: Fix focus issues for chips fields. Since its the validation part we don't want, just override that part. Let the calls that handle focus go through as planned otherwise. fixes b/5177339 Compose screen broken in Gmail Change-Id: If00069e975449bc338ad52356c44124664f1b909 --- chips/src/com/android/ex/chips/RecipientEditTextView.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/chips/src/com/android/ex/chips/RecipientEditTextView.java b/chips/src/com/android/ex/chips/RecipientEditTextView.java index feb5a07..e273456 100644 --- a/chips/src/com/android/ex/chips/RecipientEditTextView.java +++ b/chips/src/com/android/ex/chips/RecipientEditTextView.java @@ -284,15 +284,20 @@ public class RecipientEditTextView extends MultiAutoCompleteTextView implements @Override public void onFocusChanged(boolean hasFocus, int direction, Rect previous) { + super.onFocusChanged(hasFocus, direction, previous); if (!hasFocus) { shrink(); - dismissDropDown(); } else { expand(); scrollLineIntoView(getLineCount()); } } + @Override + public void performValidation() { + // Do nothing. Chips handles its own validation. + } + private void shrink() { if (mSelectedChip != null) { clearSelectedChip(); -- cgit v1.2.3