Index: cc/test/fake_content_layer_client.h |
diff --git a/cc/test/fake_content_layer_client.h b/cc/test/fake_content_layer_client.h |
index d53d34e2ea3d95ef6e716339de53df332396aa92..a4ecc590ea380b81600df28abdb8bbe2c8119b43 100644 |
--- a/cc/test/fake_content_layer_client.h |
+++ b/cc/test/fake_content_layer_client.h |
@@ -13,14 +13,24 @@ |
#include "third_party/skia/include/core/SkBitmap.h" |
#include "third_party/skia/include/core/SkPaint.h" |
#include "ui/gfx/geometry/rect.h" |
+#include "ui/gfx/transform.h" |
namespace cc { |
class FakeContentLayerClient : public ContentLayerClient { |
public: |
struct BitmapData { |
+ BitmapData(const SkBitmap& bitmap, |
+ const gfx::Point& point, |
+ const SkPaint& paint); |
+ BitmapData(const SkBitmap& bitmap, |
+ const gfx::Transform& transform, |
+ const SkPaint& paint); |
+ ~BitmapData(); |
+ |
SkBitmap bitmap; |
gfx::Point point; |
+ gfx::Transform transform; |
SkPaint paint; |
}; |
@@ -46,10 +56,14 @@ class FakeContentLayerClient : public ContentLayerClient { |
void add_draw_bitmap(const SkBitmap& bitmap, |
const gfx::Point& point, |
const SkPaint& paint) { |
- BitmapData data; |
- data.bitmap = bitmap; |
- data.point = point; |
- data.paint = paint; |
+ BitmapData data(bitmap, point, paint); |
+ draw_bitmaps_.push_back(data); |
+ } |
+ |
+ void add_draw_bitmap_with_transform(const SkBitmap& bitmap, |
+ const gfx::Transform& transform, |
+ const SkPaint& paint) { |
+ BitmapData data(bitmap, transform, paint); |
draw_bitmaps_.push_back(data); |
} |