| Index: skia/ext/platform_canvas_unittest.cc
|
| ===================================================================
|
| --- skia/ext/platform_canvas_unittest.cc (revision 165342)
|
| +++ skia/ext/platform_canvas_unittest.cc (working copy)
|
| @@ -194,7 +194,8 @@
|
| // regular skia primitives.
|
| TEST(PlatformCanvas, SkLayer) {
|
| // Create the canvas initialized to opaque white.
|
| - PlatformCanvas canvas(16, 16, true);
|
| + SkAutoTUnref<PlatformCanvas> holder(CreatePlatformCanvas(16, 16, true));
|
| + PlatformCanvas& canvas = *holder.get();
|
| canvas.drawColor(SK_ColorWHITE);
|
|
|
| // Make a layer and fill it completely to make sure that the bounds are
|
| @@ -211,7 +212,8 @@
|
| // Test native clipping.
|
| TEST(PlatformCanvas, ClipRegion) {
|
| // Initialize a white canvas
|
| - PlatformCanvas canvas(16, 16, true);
|
| + SkAutoTUnref<PlatformCanvas> holder(CreatePlatformCanvas(16, 16, true));
|
| + PlatformCanvas& canvas = *holder.get();
|
| canvas.drawColor(SK_ColorWHITE);
|
| EXPECT_TRUE(VerifyCanvasColor(canvas, SK_ColorWHITE));
|
|
|
| @@ -238,7 +240,8 @@
|
| // Test the layers get filled properly by native rendering.
|
| TEST(PlatformCanvas, FillLayer) {
|
| // Create the canvas initialized to opaque white.
|
| - PlatformCanvas canvas(16, 16, true);
|
| + SkAutoTUnref<PlatformCanvas> holder(CreatePlatformCanvas(16, 16, true));
|
| + PlatformCanvas& canvas = *holder.get();
|
|
|
| // Make a layer and fill it completely to make sure that the bounds are
|
| // correct.
|
| @@ -297,7 +300,8 @@
|
| // Test that translation + make layer works properly.
|
| TEST(PlatformCanvas, TranslateLayer) {
|
| // Create the canvas initialized to opaque white.
|
| - PlatformCanvas canvas(16, 16, true);
|
| + SkAutoTUnref<PlatformCanvas> holder(CreatePlatformCanvas(16, 16, true));
|
| + PlatformCanvas& canvas = *holder.get();
|
|
|
| // Make a layer and fill it completely to make sure that the bounds are
|
| // correct.
|
|
|