Fixed some compilation problems with debugger with robertphillips
authorrmistry@google.com <rmistry@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>
Wed, 21 Nov 2012 18:37:58 +0000 (18:37 +0000)
committerrmistry@google.com <rmistry@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>
Wed, 21 Nov 2012 18:37:58 +0000 (18:37 +0000)
git-svn-id: http://skia.googlecode.com/svn/trunk@6534 2bbb7eff-a529-9590-31e7-b0007b416f81

debugger/SkDebugCanvas.cpp
debugger/SkDrawCommand.h

index acb9a7d..03c3c16 100644 (file)
@@ -200,7 +200,8 @@ static SkBitmap createBitmap(const SkPath& path) {
 }
 
 bool SkDebugCanvas::clipPath(const SkPath& path, SkRegion::Op op, bool doAA) {
-    addDrawCommand(new ClipPath(path, op, doAA, createBitmap(path)));
+    SkBitmap bitmap = createBitmap(path);
+    addDrawCommand(new ClipPath(path, op, doAA, bitmap));
     return true;
 }
 
@@ -248,7 +249,8 @@ void SkDebugCanvas::drawPaint(const SkPaint& paint) {
 }
 
 void SkDebugCanvas::drawPath(const SkPath& path, const SkPaint& paint) {
-    addDrawCommand(new DrawPath(path, paint, createBitmap(path)));
+    SkBitmap bitmap = createBitmap(path);
+    addDrawCommand(new DrawPath(path, paint, bitmap));
 }
 
 void SkDebugCanvas::drawPicture(SkPicture& picture) {
index 5d2c065..df447a4 100644 (file)
@@ -170,7 +170,7 @@ class DrawPath : public SkDrawCommand {
 public:
     DrawPath(const SkPath& path, const SkPaint& paint, SkBitmap& bitmap);
     virtual void execute(SkCanvas* canvas) SK_OVERRIDE;
-    virtual const SkBitmap* DrawPath::getBitmap() const SK_OVERRIDE;
+    virtual const SkBitmap* getBitmap() const SK_OVERRIDE;
 
 private:
     const SkPath* fPath;