Index: src/utils/debugger/SkDebugCanvas.cpp |
diff --git a/src/utils/debugger/SkDebugCanvas.cpp b/src/utils/debugger/SkDebugCanvas.cpp |
index 08e6d94f9e58eb717f363b9a50e70ffd624bc6f9..279976a616f64ac3f80d45c35d89e72226a73e17 100644 |
--- a/src/utils/debugger/SkDebugCanvas.cpp |
+++ b/src/utils/debugger/SkDebugCanvas.cpp |
@@ -530,8 +530,9 @@ void SkDebugCanvas::onPopCull() { |
this->addDrawCommand(new SkPopCullCommand()); |
} |
-void SkDebugCanvas::restore() { |
- addDrawCommand(new SkRestoreCommand()); |
+void SkDebugCanvas::willRestore() { |
+ this->addDrawCommand(new SkRestoreCommand()); |
+ this->INHERITED::willRestore(); |
} |
bool SkDebugCanvas::rotate(SkScalar degrees) { |
@@ -539,15 +540,17 @@ bool SkDebugCanvas::rotate(SkScalar degrees) { |
return true; |
} |
-int SkDebugCanvas::save(SaveFlags flags) { |
- addDrawCommand(new SkSaveCommand(flags)); |
- return true; |
+void SkDebugCanvas::willSave(SaveFlags flags) { |
+ this->addDrawCommand(new SkSaveCommand(flags)); |
+ this->INHERITED::willSave(flags); |
} |
-int SkDebugCanvas::saveLayer(const SkRect* bounds, const SkPaint* paint, |
- SaveFlags flags) { |
- addDrawCommand(new SkSaveLayerCommand(bounds, paint, flags)); |
- return true; |
+SkCanvas::SaveLayerStrategy SkDebugCanvas::willSaveLayer(const SkRect* bounds, const SkPaint* paint, |
+ SaveFlags flags) { |
+ this->addDrawCommand(new SkSaveLayerCommand(bounds, paint, flags)); |
+ this->INHERITED::willSaveLayer(bounds, paint, flags); |
+ // No need for a full layer. |
+ return kNoLayer_SaveLayerStrategy; |
} |
bool SkDebugCanvas::scale(SkScalar sx, SkScalar sy) { |