aboutsummaryrefslogtreecommitdiffhomepage
path: root/samplecode
diff options
context:
space:
mode:
authorGravatar reed <reed@google.com>2015-06-05 11:31:26 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2015-06-05 11:31:26 -0700
commit56263c78d86cb536d463b8d46f00ac44cad3defb (patch)
treec43997464263ed75c154419ee403a54fc0ad0163 /samplecode
parentb500ffa1a253dca35a7ff846ebece9fe570e3565 (diff)
delete (unused) TransparentShader
BUG=skia: TBR= Review URL: https://codereview.chromium.org/1153193014
Diffstat (limited to 'samplecode')
-rw-r--r--samplecode/SampleAll.cpp4
-rw-r--r--samplecode/SampleShaders.cpp7
2 files changed, 2 insertions, 9 deletions
diff --git a/samplecode/SampleAll.cpp b/samplecode/SampleAll.cpp
index 9a39ef9d76..667bcc3054 100644
--- a/samplecode/SampleAll.cpp
+++ b/samplecode/SampleAll.cpp
@@ -33,7 +33,6 @@
#include "SkPathMeasure.h"
#include "SkPicture.h"
#include "SkRandom.h"
-#include "SkTransparentShader.h"
#include "SkTypeface.h"
#include "SkUtils.h"
#include "SkXfermode.h"
@@ -376,7 +375,6 @@ protected:
radialRadius, radialColors, radialPos, radialCount,
radialMode);
- SkTransparentShader* transparentShader = new SkTransparentShader();
SkEmbossMaskFilter::Light light;
light.fDirection[0] = SK_Scalar1/2;
light.fDirection[1] = SK_Scalar1/2;
@@ -428,7 +426,7 @@ protected:
paint.setMaskFilter(embossFilter)->unref();
canvas->drawOval(rect, paint);
canvas->translate(SkIntToScalar(10), SkIntToScalar(10));
- paint.setShader(transparentShader)->unref();
+// paint.setShader(transparentShader)->unref();
canvas->drawOval(rect, paint);
canvas->translate(0, SkIntToScalar(-10));
diff --git a/samplecode/SampleShaders.cpp b/samplecode/SampleShaders.cpp
index 093e14f4eb..a9a8cf9c17 100644
--- a/samplecode/SampleShaders.cpp
+++ b/samplecode/SampleShaders.cpp
@@ -20,7 +20,6 @@
#include "SkColorPriv.h"
#include "SkColorFilter.h"
#include "SkTime.h"
-#include "SkTransparentShader.h"
#include "SkTypeface.h"
static SkShader* make_bitmapfade(const SkBitmap& bm)
@@ -116,13 +115,9 @@ protected:
canvas->drawRect(r, paint);
paint.setShader(make_bitmapfade(fBitmap))->unref();
canvas->drawRect(r, paint);
-
- paint.setShader(new SkTransparentShader)->unref();
- canvas->drawRect(r, paint);
}
- virtual SkView::Click* onFindClickHandler(SkScalar x, SkScalar y,
- unsigned modi) override {
+ SkView::Click* onFindClickHandler(SkScalar x, SkScalar y, unsigned modi) override {
this->inval(NULL);
return this->INHERITED::onFindClickHandler(x, y, modi);
}