Index: tools/debugger/SkDrawCommand.cpp |
diff --git a/tools/debugger/SkDrawCommand.cpp b/tools/debugger/SkDrawCommand.cpp |
index 1af299831f22d6f6e0790b68568b077fb59404e4..33e49ce75edec556435fc5f4437c64d4a826255c 100644 |
--- a/tools/debugger/SkDrawCommand.cpp |
+++ b/tools/debugger/SkDrawCommand.cpp |
@@ -228,8 +228,7 @@ |
} |
Json::Value SkDrawCommand::drawToAndCollectJSON(SkCanvas* canvas, |
- UrlDataManager& urlDataManager, |
- int opIndex) const { |
+ UrlDataManager& urlDataManager) const { |
Json::Value result = this->toJSON(urlDataManager); |
SkASSERT(canvas); |
@@ -240,18 +239,19 @@ |
GrContext* ctx = rt->getContext(); |
if(ctx) { |
GrAuditTrail* at = ctx->getAuditTrail(); |
- GrAuditTrail::AutoCollectBatches enable(at, opIndex); |
+ GrAuditTrail::AutoEnable enable(at); |
this->execute(canvas); |
// TODO if this is inefficient we could add a method to GrAuditTrail which takes |
// a Json::Value and is only compiled in this file |
Json::Value parsedFromString; |
Json::Reader reader; |
- SkDEBUGCODE(bool parsingSuccessful = )reader.parse(at->toJson(opIndex).c_str(), |
+ SkDEBUGCODE(bool parsingSuccessful = )reader.parse(at->toJson().c_str(), |
parsedFromString); |
SkASSERT(parsingSuccessful); |
result[SKDEBUGCANVAS_ATTRIBUTE_AUDITTRAIL] = parsedFromString; |
+ at->reset(); |
} |
} |
#endif |