diff options
author | Kevin Lin <linkevin@google.com> | 2014-02-28 15:04:40 -0800 |
---|---|---|
committer | Kevin Lin <linkevin@google.com> | 2014-02-28 15:04:40 -0800 |
commit | 0c58c3707163765a65847d07ada963627eccb671 (patch) | |
tree | 71526adffc1dbfbf0c8eb85de8f90fa13a4ec4b6 | |
parent | 66df41d9647f7735b6b4d0129af078a240dcca81 (diff) | |
download | android_frameworks_ex-0c58c3707163765a65847d07ada963627eccb671.tar.gz android_frameworks_ex-0c58c3707163765a65847d07ada963627eccb671.tar.bz2 android_frameworks_ex-0c58c3707163765a65847d07ada963627eccb671.zip |
Fix redrawing chips with recipientEditText onSizeChanged when it has left and right padding.
Change-Id: I4021ddc0359f6e7a807ba4b10d12c80fc01c25a4
-rw-r--r-- | chips/src/com/android/ex/chips/RecipientEditTextView.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/chips/src/com/android/ex/chips/RecipientEditTextView.java b/chips/src/com/android/ex/chips/RecipientEditTextView.java index 5d5216e..9633587 100644 --- a/chips/src/com/android/ex/chips/RecipientEditTextView.java +++ b/chips/src/com/android/ex/chips/RecipientEditTextView.java @@ -928,7 +928,8 @@ public class RecipientEditTextView extends MultiAutoCompleteTextView implements Rect bounds; for (DrawableRecipientChip chip : chips) { bounds = chip.getBounds(); - if (getWidth() > 0 && bounds.right - bounds.left > getWidth()) { + if (getWidth() > 0 && bounds.right - bounds.left > + getWidth() - getPaddingLeft() - getPaddingRight()) { // Need to redraw that chip. replaceChip(chip, chip.getEntry()); } |