aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar fmalita <fmalita@chromium.org>2016-01-12 12:14:10 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2016-01-12 12:14:10 -0800
commit61a237e319a63b7ed6d38c2f3cd9b597816c3a46 (patch)
tree9c40e3414eaf6e6f4f6a8234a41c722a180aadd4
parent8d30dae5a0beab5015620929ba29949e2ccba903 (diff)
SkPaintFilterCanvas cleanup
All external clients have been updated, we can now remove the transitional kludges. BUG=skia:4782 R=reed@google.com GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1574303003 Review URL: https://codereview.chromium.org/1574303003
-rw-r--r--include/core/SkDrawFilter.h2
-rw-r--r--include/utils/SkPaintFilterCanvas.h10
2 files changed, 3 insertions, 9 deletions
diff --git a/include/core/SkDrawFilter.h b/include/core/SkDrawFilter.h
index 865df5f1e1..2812017b71 100644
--- a/include/core/SkDrawFilter.h
+++ b/include/core/SkDrawFilter.h
@@ -16,6 +16,8 @@ class SkCanvas;
class SkPaint;
/**
+ * DEPRECATED - use SkPaintFilterCanvas instead.
+ *
* Right before something is being draw, filter() is called with the
* paint. The filter may modify the paint as it wishes, which will then be
* used for the actual drawing. Note: this modification only lasts for the
diff --git a/include/utils/SkPaintFilterCanvas.h b/include/utils/SkPaintFilterCanvas.h
index 35e3221752..909cf3b987 100644
--- a/include/utils/SkPaintFilterCanvas.h
+++ b/include/utils/SkPaintFilterCanvas.h
@@ -58,15 +58,7 @@ protected:
* To also filter encapsulated paints (e.g. SkPicture, SkTextBlob), clients may need to
* override the relevant methods (i.e. drawPicture, drawTextBlob).
*/
- virtual bool onFilter(SkTCopyOnFirstWrite<SkPaint>* paint, Type type) const {
- if (*paint) {
- this->onFilterPaint(paint->writable(), type);
- }
- return true;
- }
-
- // DEPRECATED - do not use
- virtual void onFilterPaint(SkPaint*, Type) const { }
+ virtual bool onFilter(SkTCopyOnFirstWrite<SkPaint>* paint, Type type) const = 0;
void onDrawPaint(const SkPaint&) override;
void onDrawPoints(PointMode, size_t count, const SkPoint pts[], const SkPaint&) override;