Adding background protection to icons and apps button.

Change-Id: I650f9135c0ce5bc2a6f7c5f878d470d6a85e9f7e
This commit is contained in:
Winson Chung
2010-11-29 17:15:47 -08:00
parent f28958bc00
commit 656d11c882
11 changed files with 103 additions and 45 deletions
+7 -2
View File
@@ -1281,9 +1281,14 @@ public class Workspace extends SmoothPagedView
v.getDrawingRect(clipRect);
// For a TextView, adjust the clip rect so that we don't include the text label
if (v instanceof TextView) {
if (v instanceof BubbleTextView) {
final BubbleTextView tv = (BubbleTextView) v;
clipRect.bottom = tv.getExtendedPaddingTop() - (int) BubbleTextView.PADDING_V +
tv.getLayout().getLineTop(0);
} else if (v instanceof TextView) {
final TextView tv = (TextView) v;
clipRect.bottom = clipRect.top + tv.getCompoundPaddingTop() - 1;
clipRect.bottom = tv.getExtendedPaddingTop() - tv.getCompoundDrawablePadding() +
tv.getLayout().getLineTop(0);
}
// Draw the View into the bitmap.