diff options
| author | Gilles Debunne <debunne@google.com> | 2011-01-31 18:52:38 -0800 |
|---|---|---|
| committer | Android Git Automerger <android-git-automerger@android.com> | 2011-01-31 18:52:38 -0800 |
| commit | 6538329258ee01b27586d8b0e46e96160d719a68 (patch) | |
| tree | 44957c24812aa4fc95b346237c8824aaf3e19f48 /core/java/android/widget | |
| parent | aa9082bc799fd3d61a80d0bc95b0452100a3dca4 (diff) | |
| parent | 8f8aac5e8adfe14b8a01d90424b1815e0a0ebe28 (diff) | |
| download | frameworks_base-6538329258ee01b27586d8b0e46e96160d719a68.zip frameworks_base-6538329258ee01b27586d8b0e46e96160d719a68.tar.gz frameworks_base-6538329258ee01b27586d8b0e46e96160d719a68.tar.bz2 | |
am 8f8aac5e: Merge "Pixel were missing on the last line of text when using MaxLines." into honeycomb
* commit '8f8aac5e8adfe14b8a01d90424b1815e0a0ebe28':
Pixel were missing on the last line of text when using MaxLines.
Diffstat (limited to 'core/java/android/widget')
| -rw-r--r-- | core/java/android/widget/TextView.java | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/core/java/android/widget/TextView.java b/core/java/android/widget/TextView.java index 8cb725a..772eefd 100644 --- a/core/java/android/widget/TextView.java +++ b/core/java/android/widget/TextView.java @@ -5861,6 +5861,7 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener } desired += pad; + layout.setMaximumVisibleLineCount(0); if (mMaxMode == LINES) { /* @@ -5869,8 +5870,8 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener */ if (cap) { if (linecount > mMaximum) { - desired = layout.getLineTop(mMaximum) + - layout.getBottomPadding(); + layout.setMaximumVisibleLineCount(mMaximum); + desired = layout.getLineTop(mMaximum); if (dr != null) { desired = Math.max(desired, dr.mDrawableHeightLeft); @@ -6438,7 +6439,6 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener if (applyTransformation) { setTransformationMethod(SingleLineTransformationMethod.getInstance()); } - // TODO setState } else { if (changeMaxLines) { setMaxLines(Integer.MAX_VALUE); @@ -6447,7 +6447,6 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener if (applyTransformation) { setTransformationMethod(null); } - // TODO setState } } |
