class MyBitmapDrawable extends BitmapDrawable {
boolean isTransparent = false; @Override
public void draw(Canvas canvas) {
Bitmap b = getBitmap();
if (b != null && !isTransparent) { //if not transparent, then draw it.
canvas.drawBitmap(b, null, rect, null);
}//else do nothing}
boolean isTransparent = false; @Override
public void draw(Canvas canvas) {
Bitmap b = getBitmap();
if (b != null && !isTransparent) { //if not transparent, then draw it.
canvas.drawBitmap(b, null, rect, null);
}//else do nothing}
我已经用其它方法解决了.