Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1578)

Unified Diff: skia/ext/platform_canvas_unittest.cc

Issue 9416017: Optionally clear PlatformCanvas instances. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Address style issues. Created 8 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: skia/ext/platform_canvas_unittest.cc
===================================================================
--- skia/ext/platform_canvas_unittest.cc (revision 123041)
+++ skia/ext/platform_canvas_unittest.cc (working copy)
@@ -193,7 +193,8 @@
// regular skia primitives.
TEST(PlatformCanvas, SkLayer) {
// Create the canvas initialized to opaque white.
- PlatformCanvas canvas(16, 16, true);
+ PlatformCanvas canvas(16, 16,
+ PlatformDevice::FLAGS_OPAQUE | PlatformDevice::FLAGS_INITIALIZED);
canvas.drawColor(SK_ColorWHITE);
// Make a layer and fill it completely to make sure that the bounds are
@@ -208,7 +209,8 @@
// Test native clipping.
TEST(PlatformCanvas, ClipRegion) {
// Initialize a white canvas
- PlatformCanvas canvas(16, 16, true);
+ PlatformCanvas canvas(16, 16,
+ PlatformDevice::FLAGS_OPAQUE | PlatformDevice::FLAGS_INITIALIZED);
canvas.drawColor(SK_ColorWHITE);
EXPECT_TRUE(VerifyCanvasColor(canvas, SK_ColorWHITE));
@@ -233,7 +235,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);
+ PlatformCanvas canvas(16, 16,
+ PlatformDevice::FLAGS_OPAQUE | PlatformDevice::FLAGS_INITIALIZED);
// Make a layer and fill it completely to make sure that the bounds are
// correct.
@@ -290,7 +293,8 @@
// Test that translation + make layer works properly.
TEST(PlatformCanvas, TranslateLayer) {
// Create the canvas initialized to opaque white.
- PlatformCanvas canvas(16, 16, true);
+ PlatformCanvas canvas(16, 16,
+ PlatformDevice::FLAGS_OPAQUE | PlatformDevice::FLAGS_INITIALIZED);
// Make a layer and fill it completely to make sure that the bounds are
// correct.

Powered by Google App Engine
This is Rietveld 408576698