Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(761)

Unified Diff: gm/windowrectangles.cpp

Issue 2355483002: abstract name of clipping ops, to transtion to a more restricted set (Closed)
Patch Set: no need for ifdef for globals Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gm/skbug1719.cpp ('k') | gyp/skia_for_android_framework_defines.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/windowrectangles.cpp
diff --git a/gm/windowrectangles.cpp b/gm/windowrectangles.cpp
index 7917bc4731f8a00d5c1e5e478275a1efbbd73aaa..f1a7356a988e378fc9589d4b43046593824543fa 100644
--- a/gm/windowrectangles.cpp
+++ b/gm/windowrectangles.cpp
@@ -42,19 +42,19 @@ void WindowRectanglesBaseGM::onDraw(SkCanvas* canvas) {
canvas->saveLayer(SkRect::Make(kLayerRect), nullptr);
SkClipStack stack;
- stack.clipDevRect(SkRect::MakeXYWH(370.75, 80.25, 149, 100), SkRegion::kDifference_Op, false);
- stack.clipDevRect(SkRect::MakeXYWH(80.25, 420.75, 150, 100), SkRegion::kDifference_Op, true);
+ stack.clipDevRect(SkRect::MakeXYWH(370.75, 80.25, 149, 100), SkCanvas::kDifference_Op, false);
+ stack.clipDevRect(SkRect::MakeXYWH(80.25, 420.75, 150, 100), SkCanvas::kDifference_Op, true);
stack.clipDevRRect(SkRRect::MakeRectXY(SkRect::MakeXYWH(200, 200, 200, 200), 60, 45),
- SkRegion::kDifference_Op, true);
+ SkCanvas::kDifference_Op, true);
SkRRect nine;
nine.setNinePatch(SkRect::MakeXYWH(550 - 30.25 - 100, 370.75, 100, 150), 12, 35, 23, 20);
- stack.clipDevRRect(nine, SkRegion::kDifference_Op, true);
+ stack.clipDevRRect(nine, SkCanvas::kDifference_Op, true);
SkRRect complx;
SkVector complxRadii[4] = {{6, 4}, {8, 12}, {16, 24}, {48, 32}};
complx.setRectRadii(SkRect::MakeXYWH(80.25, 80.75, 100, 149), complxRadii);
- stack.clipDevRRect(complx, SkRegion::kDifference_Op, false);
+ stack.clipDevRRect(complx, SkCanvas::kDifference_Op, false);
this->onCoverClipStack(stack, canvas);
@@ -77,7 +77,7 @@ private:
*/
class ReplayClipStackVisitor final : public SkCanvasClipVisitor {
public:
- typedef SkRegion::Op Op;
+ typedef SkCanvas::ClipOp Op;
ReplayClipStackVisitor(SkCanvas* canvas) : fCanvas(canvas) {}
void clipRect(const SkRect& r, Op op, bool aa) override { fCanvas->clipRect(r, op, aa); }
void clipRRect(const SkRRect& rr, Op op, bool aa) override { fCanvas->clipRRect(rr, op, aa); }
« no previous file with comments | « gm/skbug1719.cpp ('k') | gyp/skia_for_android_framework_defines.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698