summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDaniel Sandler <dsandler@google.com>2009-11-04 11:07:14 -0500
committerDaniel Sandler <dsandler@google.com>2009-11-04 11:07:14 -0500
commitdf807b99f41a1fe3237c13e52fd36482df4eb92b (patch)
treef1c60515e2c9f3fbf975ff473755de10f3ba65df /src
parent02d03b0212e69dc08814b6f81e3bd3d819316013 (diff)
downloadandroid_packages_wallpapers_LivePicker-df807b99f41a1fe3237c13e52fd36482df4eb92b.zip
android_packages_wallpapers_LivePicker-df807b99f41a1fe3237c13e52fd36482df4eb92b.tar.gz
android_packages_wallpapers_LivePicker-df807b99f41a1fe3237c13e52fd36482df4eb92b.tar.bz2
Fix live wallpaper picker crash on launch.
Diffstat (limited to 'src')
-rw-r--r--src/com/android/wallpaper/livepicker/BubbleTextView.java47
1 files changed, 0 insertions, 47 deletions
diff --git a/src/com/android/wallpaper/livepicker/BubbleTextView.java b/src/com/android/wallpaper/livepicker/BubbleTextView.java
index 3ac5605..5b1bf80 100644
--- a/src/com/android/wallpaper/livepicker/BubbleTextView.java
+++ b/src/com/android/wallpaper/livepicker/BubbleTextView.java
@@ -37,7 +37,6 @@ public class BubbleTextView extends TextView {
private Paint mPaint;
private boolean mBackgroundSizeChanged;
- private Drawable mBackground;
private float mCornerRadius;
private float mPaddingH;
private float mPaddingV;
@@ -58,7 +57,6 @@ public class BubbleTextView extends TextView {
}
private void init() {
- mBackground = getBackground();
setBackgroundDrawable(null);
mPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
@@ -80,40 +78,7 @@ public class BubbleTextView extends TextView {
}
@Override
- protected boolean verifyDrawable(Drawable who) {
- return who == mBackground || super.verifyDrawable(who);
- }
-
- @Override
- protected void drawableStateChanged() {
- Drawable d = mBackground;
- if (d != null && d.isStateful()) {
- d.setState(getDrawableState());
- }
- super.drawableStateChanged();
- }
-
- @Override
public void draw(Canvas canvas) {
- final Drawable background = mBackground;
- if (background != null) {
- final int scrollX = mScrollX;
- final int scrollY = mScrollY;
-
- if (mBackgroundSizeChanged) {
- background.setBounds(0, 0, mRight - mLeft, mBottom - mTop);
- mBackgroundSizeChanged = false;
- }
-
- if ((scrollX | scrollY) == 0) {
- background.draw(canvas);
- } else {
- canvas.translate(scrollX, scrollY);
- background.draw(canvas);
- canvas.translate(-scrollX, -scrollY);
- }
- }
-
final Layout layout = getLayout();
final RectF rect = mRect;
final int left = getCompoundPaddingLeft();
@@ -127,16 +92,4 @@ public class BubbleTextView extends TextView {
super.draw(canvas);
}
-
- @Override
- protected void onAttachedToWindow() {
- super.onAttachedToWindow();
- mBackground.setCallback(this);
- }
-
- @Override
- protected void onDetachedFromWindow() {
- super.onDetachedFromWindow();
- mBackground.setCallback(null);
- }
}