diff options
author | robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2014-02-28 18:19:39 +0000 |
---|---|---|
committer | robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2014-02-28 18:19:39 +0000 |
commit | 8f90a892c5130d4d26b5588e1ff151d01a40688a (patch) | |
tree | c21277731de84a5059659df199659fee9352842c /tests | |
parent | 069c2a46ba2dc419dcd7dbcb9bf3b83c49b45b41 (diff) |
add new onClip* methods to SkCanvas
https://codereview.chromium.org/183453002/
git-svn-id: http://skia.googlecode.com/svn/trunk@13627 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'tests')
-rw-r--r-- | tests/PictureTest.cpp | 26 |
1 files changed, 17 insertions, 9 deletions
diff --git a/tests/PictureTest.cpp b/tests/PictureTest.cpp index 89f0af43fb..c6afb1f9da 100644 --- a/tests/PictureTest.cpp +++ b/tests/PictureTest.cpp @@ -982,22 +982,30 @@ public: , fClipCount(0){ } - virtual bool clipRect(const SkRect& r, SkRegion::Op op, bool doAA) - SK_OVERRIDE { + virtual void onClipRect(const SkRect& r, + SkRegion::Op op, + ClipEdgeStyle edgeStyle) SK_OVERRIDE { fClipCount += 1; - return this->INHERITED::clipRect(r, op, doAA); + this->INHERITED::onClipRect(r, op, edgeStyle); } - virtual bool clipRRect(const SkRRect& rrect, SkRegion::Op op, bool doAA) - SK_OVERRIDE { + virtual void onClipRRect(const SkRRect& rrect, + SkRegion::Op op, + ClipEdgeStyle edgeStyle)SK_OVERRIDE { fClipCount += 1; - return this->INHERITED::clipRRect(rrect, op, doAA); + this->INHERITED::onClipRRect(rrect, op, edgeStyle); } - virtual bool clipPath(const SkPath& path, SkRegion::Op op, bool doAA) - SK_OVERRIDE { + virtual void onClipPath(const SkPath& path, + SkRegion::Op op, + ClipEdgeStyle edgeStyle) SK_OVERRIDE { fClipCount += 1; - return this->INHERITED::clipPath(path, op, doAA); + this->INHERITED::onClipPath(path, op, edgeStyle); + } + + virtual void onClipRegion(const SkRegion& deviceRgn, SkRegion::Op op) SK_OVERRIDE { + fClipCount += 1; + this->INHERITED::onClipRegion(deviceRgn, op); } unsigned getClipCount() const { return fClipCount; } |