aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/core/SkCanvas.h
diff options
context:
space:
mode:
authorGravatar Florin Malita <fmalita@chromium.org>2014-06-30 10:13:28 -0400
committerGravatar Florin Malita <fmalita@chromium.org>2014-06-30 10:13:28 -0400
commit5f6102d07982043542343ff0a6c67b1319ac9fc7 (patch)
tree934909d391ec4f68bcb9c27a327f540c292ca8b3 /include/core/SkCanvas.h
parentfdecca84400688c5a683da32ec11f6282e9a6b14 (diff)
SaveFlags be-gone
Remove the deprecated save(SaveFlags), willSave(SaveFlags) and all traces of kMatrix_SaveFlags/kClip_SaveFlag. BUG=skia:2297 R=mtklein@google.com, reed@google.com, robertphillips@google.com Review URL: https://codereview.chromium.org/340403003
Diffstat (limited to 'include/core/SkCanvas.h')
-rw-r--r--include/core/SkCanvas.h27
1 files changed, 4 insertions, 23 deletions
diff --git a/include/core/SkCanvas.h b/include/core/SkCanvas.h
index 8640d729b0..7a4ddd935f 100644
--- a/include/core/SkCanvas.h
+++ b/include/core/SkCanvas.h
@@ -293,9 +293,9 @@ public:
enum SaveFlags {
/** save the matrix state, restoring it on restore() */
- kMatrix_SaveFlag = 0x01,
+ // [deprecated] kMatrix_SaveFlag = 0x01,
/** save the clip state, restoring it on restore() */
- kClip_SaveFlag = 0x02,
+ // [deprecated] kClip_SaveFlag = 0x02,
/** the layer needs to support per-pixel alpha */
kHasAlphaLayer_SaveFlag = 0x04,
/** the layer needs to support 8-bits per color component */
@@ -308,7 +308,7 @@ public:
kClipToLayer_SaveFlag = 0x10,
// helper masks for common choices
- kMatrixClip_SaveFlag = 0x03,
+ // [deprecated] kMatrixClip_SaveFlag = 0x03,
#ifdef SK_SUPPORT_LEGACY_CLIPTOLAYERFLAG
kARGB_NoClipLayer_SaveFlag = 0x0F,
#endif
@@ -326,22 +326,6 @@ public:
*/
int save();
- /** DEPRECATED - use save() instead.
-
- This behaves the same as save(), but it allows fine-grained control of
- which state bits to be saved (and subsequently restored).
-
- @param flags The flags govern what portion of the Matrix/Clip/drawFilter
- state the save (and matching restore) effect. For example,
- if only kMatrix is specified, then only the matrix state
- will be pushed and popped. Likewise for the clip if kClip
- is specified. However, the drawFilter is always affected
- by calls to save/restore.
- @return The value to pass to restoreToCount() to balance this save()
- */
- SK_ATTR_EXTERNALLY_DEPRECATED("SaveFlags use is deprecated")
- int save(SaveFlags flags);
-
/** This behaves the same as save(), but in addition it allocates an
offscreen bitmap. All drawing calls are directed there, and only when
the balancing call to restore() is made is that offscreen transfered to
@@ -1191,9 +1175,6 @@ protected:
kNoLayer_SaveLayerStrategy
};
- // Transitional, pending external clients cleanup.
- virtual void willSave(SaveFlags) { this->willSave(); }
-
virtual void willSave() {}
virtual SaveLayerStrategy willSaveLayer(const SkRect*, const SkPaint*, SaveFlags) {
return kFullLayer_SaveLayerStrategy;
@@ -1324,7 +1305,7 @@ private:
void internalDrawDevice(SkBaseDevice*, int x, int y, const SkPaint*);
// shared by save() and saveLayer()
- int internalSave(SaveFlags flags);
+ int internalSave();
void internalRestore();
static void DrawRect(const SkDraw& draw, const SkPaint& paint,
const SkRect& r, SkScalar textSize);