re-re-land 5578

will follow w/ new .skp files to keep the waterfall green (I hope)



git-svn-id: http://skia.googlecode.com/svn/trunk@5584 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/src/pipe/SkGPipeWrite.cpp b/src/pipe/SkGPipeWrite.cpp
index b41ebb7..f0b4e0a 100644
--- a/src/pipe/SkGPipeWrite.cpp
+++ b/src/pipe/SkGPipeWrite.cpp
@@ -221,7 +221,7 @@
     virtual void drawPath(const SkPath& path, const SkPaint&) SK_OVERRIDE;
     virtual void drawBitmap(const SkBitmap&, SkScalar left, SkScalar top,
                             const SkPaint*) SK_OVERRIDE;
-    virtual void drawBitmapRect(const SkBitmap&, const SkIRect* src,
+    virtual void drawBitmapRectToRect(const SkBitmap&, const SkRect* src,
                                 const SkRect& dst, const SkPaint*) SK_OVERRIDE;
     virtual void drawBitmapMatrix(const SkBitmap&, const SkMatrix&,
                                   const SkPaint*) SK_OVERRIDE;
@@ -732,7 +732,7 @@
     }
 }
 
-void SkGPipeCanvas::drawBitmapRect(const SkBitmap& bm, const SkIRect* src,
+void SkGPipeCanvas::drawBitmapRectToRect(const SkBitmap& bm, const SkRect* src,
                                    const SkRect& dst, const SkPaint* paint) {
     NOTIFY_SETUP(this);
     size_t opBytesNeeded = sizeof(SkRect);
@@ -745,12 +745,9 @@
         flags = 0;
     }
 
-    if (this->commonDrawBitmap(bm, kDrawBitmapRect_DrawOp, flags, opBytesNeeded, paint)) {
+    if (this->commonDrawBitmap(bm, kDrawBitmapRectToRect_DrawOp, flags, opBytesNeeded, paint)) {
         if (hasSrc) {
-            fWriter.write32(src->fLeft);
-            fWriter.write32(src->fTop);
-            fWriter.write32(src->fRight);
-            fWriter.write32(src->fBottom);
+            fWriter.writeRect(*src);
         }
         fWriter.writeRect(dst);
     }