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

Unified Diff: include/core/SkCanvas.h

Issue 340403003: SaveFlags be-gone (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: Created 6 years, 6 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/canvasstate.cpp ('k') | include/utils/SkDeferredCanvas.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkCanvas.h
diff --git a/include/core/SkCanvas.h b/include/core/SkCanvas.h
index a08e82800c953a344434c2167136e6b9e77a5ea8..fd52dbd79d170d06dc80a7ffeaefad02dea16522 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,
f(malita) 2014/06/19 17:24:48 Should we leave this in for archeological reasons?
/** 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
@@ -1200,9 +1184,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;
@@ -1333,7 +1314,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);
« no previous file with comments | « gm/canvasstate.cpp ('k') | include/utils/SkDeferredCanvas.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698