Index: gm/rectangletexture.cpp |
diff --git a/gm/rectangletexture.cpp b/gm/rectangletexture.cpp |
index 20f2ead593674d3dfa52b2b006530769e5beb849..4bdb4c9f1193ad38646240557ff0e318b76df16b 100644 |
--- a/gm/rectangletexture.cpp |
+++ b/gm/rectangletexture.cpp |
@@ -42,14 +42,14 @@ protected: |
SkCanvas canvas(bmp); |
SkPoint pts[] = { {0, 0}, {0, SkIntToScalar(height)} }; |
SkColor colors0[] = { 0xFF1060B0 , 0xFF102030 }; |
- paint.setShader(SkGradientShader::CreateLinear(pts, colors0, nullptr, 2, |
- SkShader::kClamp_TileMode))->unref(); |
+ paint.setShader(SkGradientShader::MakeLinear(pts, colors0, nullptr, 2, |
+ SkShader::kClamp_TileMode)); |
canvas.drawPaint(paint); |
SkColor colors1[] = { 0xFFA07010 , 0xFFA02080 }; |
paint.setAntiAlias(true); |
- paint.setShader(SkGradientShader::CreateLinear(pts, colors1, nullptr, 2, |
- SkShader::kClamp_TileMode))->unref(); |
+ paint.setShader(SkGradientShader::MakeLinear(pts, colors1, nullptr, 2, |
+ SkShader::kClamp_TileMode)); |
canvas.drawCircle(SkIntToScalar(width) / 2, SkIntToScalar(height) / 2, |
SkIntToScalar(width + height) / 5, paint); |
} |