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

Unified Diff: src/core/SkPicturePlayback.cpp

Issue 1533953002: change signature for virtual related to saveLayer, passing SaveLayerRec (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: update comment Created 5 years 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 | « src/core/SkPictureFlat.h ('k') | src/core/SkPictureRecord.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkPicturePlayback.cpp
diff --git a/src/core/SkPicturePlayback.cpp b/src/core/SkPicturePlayback.cpp
index 9b27a3d1e91067b2368a1b664dc0430c1799a183..187eeb96e14bb08498372cc3475fbde13f6ede80 100644
--- a/src/core/SkPicturePlayback.cpp
+++ b/src/core/SkPicturePlayback.cpp
@@ -455,10 +455,17 @@ void SkPicturePlayback::handleOp(SkReader32* reader,
}
canvas->save();
break;
- case SAVE_LAYER: {
+ case SAVE_LAYER_SAVEFLAGS_DEPRECATED: {
const SkRect* boundsPtr = get_rect_ptr(reader);
const SkPaint* paint = fPictureData->getPaint(reader);
- canvas->saveLayer(boundsPtr, paint, (SkCanvas::SaveFlags) reader->readInt());
+ const SkCanvas::SaveFlags flags = (SkCanvas::SaveFlags)reader->readInt();
+ canvas->saveLayer(SkCanvas::SaveLayerRec(boundsPtr, paint,
+ SkCanvas::SaveFlagsToSaveLayerFlags(flags)));
+ } break;
+ case SAVE_LAYER_SAVELAYERFLAGS: {
+ const SkRect* boundsPtr = get_rect_ptr(reader);
+ const SkPaint* paint = fPictureData->getPaint(reader);
+ canvas->saveLayer(SkCanvas::SaveLayerRec(boundsPtr, paint, reader->readInt()));
} break;
case SCALE: {
SkScalar sx = reader->readScalar();
« no previous file with comments | « src/core/SkPictureFlat.h ('k') | src/core/SkPictureRecord.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698