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

Unified Diff: src/core/SkPicturePlayback.cpp

Issue 340403003: SaveFlags be-gone (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: One more baseurl attempt 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 | « src/core/SkMatrixClipStateMgr.cpp ('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 148237a5a8ffee471e96158f2f5356f518b0e3cd..35e66bb7eb360c38ac6ea7baf4a1107d043a141d 100644
--- a/src/core/SkPicturePlayback.cpp
+++ b/src/core/SkPicturePlayback.cpp
@@ -1307,7 +1307,12 @@ void SkPicturePlayback::draw(SkCanvas& canvas, SkDrawPictureCallback* callback)
canvas.rotate(reader.readScalar());
break;
case SAVE:
- canvas.save((SkCanvas::SaveFlags) reader.readInt());
+ // SKPs with version < 29 also store a SaveFlags param.
+ if (size > 4) {
+ SkASSERT(8 == size);
+ reader.readInt();
+ }
+ canvas.save();
break;
case SAVE_LAYER: {
const SkRect* boundsPtr = this->getRectPtr(reader);
« no previous file with comments | « src/core/SkMatrixClipStateMgr.cpp ('k') | src/core/SkPictureRecord.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698