Loading graphics/java/android/graphics/drawable/ShapeDrawable.java +12 −9 Original line number Diff line number Diff line Loading @@ -217,6 +217,8 @@ public class ShapeDrawable extends Drawable { int prevAlpha = paint.getAlpha(); paint.setAlpha(modulateAlpha(prevAlpha, mShapeState.mAlpha)); // only draw shape if it may affect output if (paint.getAlpha() != 0 || paint.getXfermode() != null || paint.hasShadow) { if (mShapeState.mShape != null) { // need the save both for the translate, and for the (unknown) Shape int count = canvas.save(); Loading @@ -226,6 +228,7 @@ public class ShapeDrawable extends Drawable { } else { canvas.drawRect(r, paint); } } // restore paint.setAlpha(prevAlpha); Loading Loading
graphics/java/android/graphics/drawable/ShapeDrawable.java +12 −9 Original line number Diff line number Diff line Loading @@ -217,6 +217,8 @@ public class ShapeDrawable extends Drawable { int prevAlpha = paint.getAlpha(); paint.setAlpha(modulateAlpha(prevAlpha, mShapeState.mAlpha)); // only draw shape if it may affect output if (paint.getAlpha() != 0 || paint.getXfermode() != null || paint.hasShadow) { if (mShapeState.mShape != null) { // need the save both for the translate, and for the (unknown) Shape int count = canvas.save(); Loading @@ -226,6 +228,7 @@ public class ShapeDrawable extends Drawable { } else { canvas.drawRect(r, paint); } } // restore paint.setAlpha(prevAlpha); Loading