diff options
author | reed <reed@chromium.org> | 2015-12-20 20:08:42 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-12-20 20:08:43 -0800 |
commit | 2d6ba6690f8951e152d8e793191b14afd52f5506 (patch) | |
tree | ff71833d1327c08c9e31451d2a18286fc95f7bb0 /include | |
parent | d63f60a36327e9580861205ebb35cade8c49bd34 (diff) |
Revert of change all factories to return their base-class (patchset #1 id:1 of https://codereview.chromium.org/1535353002/ )
Reason for revert:
need to update some chrome/blink call-sites
Original issue's description:
> change all factories to return their base-class
>
> will watch DEPS roll to see if there are chrome sites needing updates
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1535353002
>
> TBR=
>
> Committed: https://skia.googlesource.com/skia/+/d63f60a36327e9580861205ebb35cade8c49bd34
TBR=
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:
Review URL: https://codereview.chromium.org/1540203002
Diffstat (limited to 'include')
-rw-r--r-- | include/effects/Sk1DPathEffect.h | 3 | ||||
-rw-r--r-- | include/effects/Sk2DPathEffect.h | 4 | ||||
-rw-r--r-- | include/effects/SkBlurDrawLooper.h | 4 | ||||
-rw-r--r-- | include/effects/SkColorMatrixFilter.h | 4 | ||||
-rw-r--r-- | include/effects/SkCornerPathEffect.h | 5 | ||||
-rw-r--r-- | include/effects/SkDashPathEffect.h | 3 | ||||
-rw-r--r-- | include/effects/SkDiscretePathEffect.h | 4 | ||||
-rw-r--r-- | include/effects/SkDisplacementMapEffect.h | 10 | ||||
-rw-r--r-- | include/effects/SkEmbossMaskFilter.h | 2 | ||||
-rw-r--r-- | include/effects/SkMatrixConvolutionImageFilter.h | 18 | ||||
-rw-r--r-- | include/effects/SkXfermodeImageFilter.h | 6 |
11 files changed, 33 insertions, 30 deletions
diff --git a/include/effects/Sk1DPathEffect.h b/include/effects/Sk1DPathEffect.h index 3419dc23b7..6a7804f111 100644 --- a/include/effects/Sk1DPathEffect.h +++ b/include/effects/Sk1DPathEffect.h @@ -56,7 +56,8 @@ public: @param style how to transform path at each point (based on the current position and tangent) */ - static SkPathEffect* Create(const SkPath& path, SkScalar advance, SkScalar phase, Style style) { + static SkPath1DPathEffect* Create(const SkPath& path, SkScalar advance, SkScalar phase, + Style style) { return new SkPath1DPathEffect(path, advance, phase, style); } diff --git a/include/effects/Sk2DPathEffect.h b/include/effects/Sk2DPathEffect.h index 73da83c4b9..fa12dcf095 100644 --- a/include/effects/Sk2DPathEffect.h +++ b/include/effects/Sk2DPathEffect.h @@ -55,7 +55,7 @@ private: class SK_API SkLine2DPathEffect : public Sk2DPathEffect { public: - static SkPathEffect* Create(SkScalar width, const SkMatrix& matrix) { + static SkLine2DPathEffect* Create(SkScalar width, const SkMatrix& matrix) { return new SkLine2DPathEffect(width, matrix); } @@ -84,7 +84,7 @@ public: * Stamp the specified path to fill the shape, using the matrix to define * the latice. */ - static SkPathEffect* Create(const SkMatrix& matrix, const SkPath& path) { + static SkPath2DPathEffect* Create(const SkMatrix& matrix, const SkPath& path) { return new SkPath2DPathEffect(matrix, path); } diff --git a/include/effects/SkBlurDrawLooper.h b/include/effects/SkBlurDrawLooper.h index 930af15ff8..808557b9da 100644 --- a/include/effects/SkBlurDrawLooper.h +++ b/include/effects/SkBlurDrawLooper.h @@ -35,8 +35,8 @@ public: kAll_BlurFlag = 0x07 }; - static SkDrawLooper* Create(SkColor color, SkScalar sigma, SkScalar dx, SkScalar dy, - uint32_t flags = kNone_BlurFlag) { + static SkBlurDrawLooper* Create(SkColor color, SkScalar sigma, SkScalar dx, SkScalar dy, + uint32_t flags = kNone_BlurFlag) { return new SkBlurDrawLooper(color, sigma, dx, dy, flags); } diff --git a/include/effects/SkColorMatrixFilter.h b/include/effects/SkColorMatrixFilter.h index 057e5cc325..bd2b939a43 100644 --- a/include/effects/SkColorMatrixFilter.h +++ b/include/effects/SkColorMatrixFilter.h @@ -13,10 +13,10 @@ class SK_API SkColorMatrixFilter : public SkColorFilter { public: - static SkColorFilter* Create(const SkColorMatrix& cm) { + static SkColorMatrixFilter* Create(const SkColorMatrix& cm) { return new SkColorMatrixFilter(cm); } - static SkColorFilter* Create(const SkScalar array[20]) { + static SkColorMatrixFilter* Create(const SkScalar array[20]) { return new SkColorMatrixFilter(array); } diff --git a/include/effects/SkCornerPathEffect.h b/include/effects/SkCornerPathEffect.h index 13095f0e6c..4c8908575d 100644 --- a/include/effects/SkCornerPathEffect.h +++ b/include/effects/SkCornerPathEffect.h @@ -20,7 +20,8 @@ public: /** radius must be > 0 to have an effect. It specifies the distance from each corner that should be "rounded". */ - static SkPathEffect* Create(SkScalar radius) { return new SkCornerPathEffect(radius); } + static SkCornerPathEffect* Create(SkScalar radius) { return new SkCornerPathEffect(radius); } + virtual ~SkCornerPathEffect(); virtual bool filterPath(SkPath* dst, const SkPath& src, SkStrokeRec*, const SkRect*) const override; @@ -33,8 +34,6 @@ public: #endif protected: - virtual ~SkCornerPathEffect(); - explicit SkCornerPathEffect(SkScalar radius); void flatten(SkWriteBuffer&) const override; diff --git a/include/effects/SkDashPathEffect.h b/include/effects/SkDashPathEffect.h index 3c1407b725..d3adeed99a 100644 --- a/include/effects/SkDashPathEffect.h +++ b/include/effects/SkDashPathEffect.h @@ -36,7 +36,8 @@ public: Note: only affects stroked paths. */ - static SkPathEffect* Create(const SkScalar intervals[], int count, SkScalar phase) { + static SkDashPathEffect* Create(const SkScalar intervals[], int count, + SkScalar phase) { return new SkDashPathEffect(intervals, count, phase); } virtual ~SkDashPathEffect(); diff --git a/include/effects/SkDiscretePathEffect.h b/include/effects/SkDiscretePathEffect.h index a49e2d89a7..b55dca8644 100644 --- a/include/effects/SkDiscretePathEffect.h +++ b/include/effects/SkDiscretePathEffect.h @@ -29,7 +29,9 @@ public: they can pass in a different seedAssist to get a different set of path segments. */ - static SkPathEffect* Create(SkScalar segLength, SkScalar deviation, uint32_t seedAssist = 0) { + static SkDiscretePathEffect* Create(SkScalar segLength, + SkScalar deviation, + uint32_t seedAssist=0) { return new SkDiscretePathEffect(segLength, deviation, seedAssist); } diff --git a/include/effects/SkDisplacementMapEffect.h b/include/effects/SkDisplacementMapEffect.h index e94461795b..253dabe0bd 100644 --- a/include/effects/SkDisplacementMapEffect.h +++ b/include/effects/SkDisplacementMapEffect.h @@ -23,11 +23,11 @@ public: ~SkDisplacementMapEffect(); - static SkImageFilter* Create(ChannelSelectorType xChannelSelector, - ChannelSelectorType yChannelSelector, - SkScalar scale, SkImageFilter* displacement, - SkImageFilter* color = NULL, - const CropRect* cropRect = NULL); + static SkDisplacementMapEffect* Create(ChannelSelectorType xChannelSelector, + ChannelSelectorType yChannelSelector, + SkScalar scale, SkImageFilter* displacement, + SkImageFilter* color = NULL, + const CropRect* cropRect = NULL); SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkDisplacementMapEffect) diff --git a/include/effects/SkEmbossMaskFilter.h b/include/effects/SkEmbossMaskFilter.h index 72020bf3ce..b6bd1a1642 100644 --- a/include/effects/SkEmbossMaskFilter.h +++ b/include/effects/SkEmbossMaskFilter.h @@ -23,7 +23,7 @@ public: uint8_t fSpecular; // exponent, 4.4 right now }; - static SkMaskFilter* Create(SkScalar blurSigma, const Light& light); + static SkEmbossMaskFilter* Create(SkScalar blurSigma, const Light& light); // overrides from SkMaskFilter // This method is not exported to java. diff --git a/include/effects/SkMatrixConvolutionImageFilter.h b/include/effects/SkMatrixConvolutionImageFilter.h index 7a2026c86b..09a3acf31a 100644 --- a/include/effects/SkMatrixConvolutionImageFilter.h +++ b/include/effects/SkMatrixConvolutionImageFilter.h @@ -52,15 +52,15 @@ public: passed to filterImage() is used instead. @param cropRect The rectangle to which the output processing will be limited. */ - static SkImageFilter* Create(const SkISize& kernelSize, - const SkScalar* kernel, - SkScalar gain, - SkScalar bias, - const SkIPoint& kernelOffset, - TileMode tileMode, - bool convolveAlpha, - SkImageFilter* input = NULL, - const CropRect* cropRect = NULL); + static SkMatrixConvolutionImageFilter* Create(const SkISize& kernelSize, + const SkScalar* kernel, + SkScalar gain, + SkScalar bias, + const SkIPoint& kernelOffset, + TileMode tileMode, + bool convolveAlpha, + SkImageFilter* input = NULL, + const CropRect* cropRect = NULL); SK_TO_STRING_OVERRIDE() SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkMatrixConvolutionImageFilter) diff --git a/include/effects/SkXfermodeImageFilter.h b/include/effects/SkXfermodeImageFilter.h index d59b7a2b25..57fd288f24 100644 --- a/include/effects/SkXfermodeImageFilter.h +++ b/include/effects/SkXfermodeImageFilter.h @@ -23,9 +23,9 @@ class SK_API SkXfermodeImageFilter : public SkImageFilter { public: virtual ~SkXfermodeImageFilter(); - static SkImageFilter* Create(SkXfermode* mode, SkImageFilter* background, - SkImageFilter* foreground = NULL, - const CropRect* cropRect = NULL) { + static SkXfermodeImageFilter* Create(SkXfermode* mode, SkImageFilter* background, + SkImageFilter* foreground = NULL, + const CropRect* cropRect = NULL) { SkImageFilter* inputs[2] = { background, foreground }; return new SkXfermodeImageFilter(mode, inputs, cropRect); } |