Index: dm/DMPDFRasterizeTask.cpp |
diff --git a/dm/DMPDFRasterizeTask.cpp b/dm/DMPDFRasterizeTask.cpp |
index ce6c10982fb503304d0ff8912ab01449aa8bf6b5..43be6e5805b5a2ea08d56b68ed0abeccfa9f5881 100644 |
--- a/dm/DMPDFRasterizeTask.cpp |
+++ b/dm/DMPDFRasterizeTask.cpp |
@@ -17,24 +17,20 @@ namespace DM { |
PDFRasterizeTask::PDFRasterizeTask(const Task& parent, |
SkData* pdf, |
- const Expectations& expectations, |
RasterizePdfProc proc) |
: CpuTask(parent) |
, fName(UnderJoin(parent.name().c_str(), "rasterize")) |
, fPdf(SkRef(pdf)) |
- , fExpectations(expectations) |
, fRasterize(proc) {} |
void PDFRasterizeTask::draw() { |
SkMemoryStream pdfStream(fPdf.get()); |
SkBitmap bitmap; |
- if (!fRasterize(&pdfStream, &bitmap)) { |
- this->fail(); |
- } |
- if (!fExpectations.check(*this, bitmap)) { |
- this->fail(); |
+ if (fRasterize(&pdfStream, &bitmap)) { |
this->spawnChild(SkNEW_ARGS(WriteTask, (*this, bitmap))); |
+ } else { |
+ this->fail(); |
} |
} |