From 322044abe4affc29999398663007c57f664bc4fa Mon Sep 17 00:00:00 2001 From: Gilles Debunne Date: Wed, 22 Feb 2012 12:01:40 -0800 Subject: Added bottom padding in textview's focused rectangle Bug 6017386 Focused rect in used in ViewRoot when a new view takes focus. TextView bringPointIntoView defines an other rectangle as text is typed. Make sure the latter is included in the former to avoid the jump when one starts typing text. Change-Id: I0177adc046c77a5fd9c1423c0069d5b9798dc0b9 --- core/java/android/widget/TextView.java | 2 ++ 1 file changed, 2 insertions(+) (limited to 'core/java/android/widget/TextView.java') diff --git a/core/java/android/widget/TextView.java b/core/java/android/widget/TextView.java index 1241c0f..dff2fec 100644 --- a/core/java/android/widget/TextView.java +++ b/core/java/android/widget/TextView.java @@ -5144,6 +5144,8 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener paddingTop += getVerticalOffset(false); } r.offset(paddingLeft, paddingTop); + int paddingBottom = getExtendedPaddingBottom(); + r.bottom += paddingBottom; } /** -- cgit v1.1