diff options
author | reed@google.com <reed@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2014-03-10 19:47:58 +0000 |
---|---|---|
committer | reed@google.com <reed@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2014-03-10 19:47:58 +0000 |
commit | b93ba45b58ad24e0e2cb75b842e24ff711c368b0 (patch) | |
tree | 10ea8de391bbc7663cca97e66ac3a83a22537dcb /gm/canvasstate.cpp | |
parent | bf998240837d8798e0b257416ce8832250b64af6 (diff) |
flag to make kClipToLayer_SaveFlag the default behavior
#define SK_SUPPORT_LEGACY_CLIPTOLAYERFLAG to get the old behavior
The goal is to remove the feature of saveLayer that allows the canvas to draw outside of the top-most layer.
R=robertphillips@google.com, scroggo@google.com
Review URL: https://codereview.chromium.org/190723004
git-svn-id: http://skia.googlecode.com/svn/trunk@13730 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'gm/canvasstate.cpp')
-rw-r--r-- | gm/canvasstate.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gm/canvasstate.cpp b/gm/canvasstate.cpp index f2761da1cb..b61ee720d5 100644 --- a/gm/canvasstate.cpp +++ b/gm/canvasstate.cpp @@ -132,6 +132,7 @@ protected: // clear the canvas to red canvas->drawColor(SK_ColorRED); +#ifdef SK_SUPPORT_LEGACY_CLIPTOLAYERFLAG // both rects should appear drawTestPattern(canvas, 255, SkCanvas::kARGB_NoClipLayer_SaveFlag); @@ -144,6 +145,7 @@ protected: // only the bottom rect should appear drawTestPattern(canvas, 0, SkCanvas::kARGB_NoClipLayer_SaveFlag); +#endif } virtual uint32_t onGetFlags() const SK_OVERRIDE { return kSkipGPU_Flag; } |