From 41014a5cd8f4500ef7fa5b87d784e50c428f69ac Mon Sep 17 00:00:00 2001 From: Peter Osterlund Date: Fri, 15 Jun 2012 22:19:27 +0000 Subject: [PATCH] DroidFish: Small optimization. --- DroidFish/src/org/petero/droidfish/SVGPictureDrawable.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/DroidFish/src/org/petero/droidfish/SVGPictureDrawable.java b/DroidFish/src/org/petero/droidfish/SVGPictureDrawable.java index 4df7d13..4dd1132 100644 --- a/DroidFish/src/org/petero/droidfish/SVGPictureDrawable.java +++ b/DroidFish/src/org/petero/droidfish/SVGPictureDrawable.java @@ -6,7 +6,6 @@ import android.graphics.Bitmap; import android.graphics.Canvas; import android.graphics.Rect; import android.graphics.RectF; -import android.graphics.drawable.BitmapDrawable; import android.graphics.drawable.PictureDrawable; /** @@ -52,7 +51,7 @@ public class SVGPictureDrawable extends PictureDrawable { if (!b.equals(cachedBounds)) { Bitmap bm = Bitmap.createBitmap(b.right-b.left, b.bottom-b.top, Bitmap.Config.ARGB_8888); Canvas bmCanvas = new Canvas(bm); - bmCanvas.drawPicture(getPicture(), getBounds()); + bmCanvas.drawPicture(getPicture(), b); cachedBitmap = bm; cachedBounds = b; }