switch GatherPixelRefs to use SkBaseDevice instead of SkBitmapDevice

BUG=
R=robertphillips@google.com, scroggo@google.com

Review URL: https://codereview.chromium.org/70473003

git-svn-id: http://skia.googlecode.com/svn/trunk/include@12259 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/core/SkBitmapDevice.h b/core/SkBitmapDevice.h
index 530b85c..b526526 100644
--- a/core/SkBitmapDevice.h
+++ b/core/SkBitmapDevice.h
@@ -73,13 +73,6 @@
     */
     virtual int height() const SK_OVERRIDE { return fBitmap.height(); }
 
-    /**
-     *  Return the bounds of the device in the coordinate space of the root
-     *  canvas. The root device will have its top-left at 0,0, but other devices
-     *  such as those associated with saveLayer may have a non-zero origin.
-     */
-    virtual void getGlobalBounds(SkIRect* bounds) const SK_OVERRIDE;
-
     /** Returns true if the device's bitmap's config treats every pixels as
         implicitly opaque.
     */
diff --git a/core/SkDevice.h b/core/SkDevice.h
index 22a56d0..3b925df 100644
--- a/core/SkDevice.h
+++ b/core/SkDevice.h
@@ -83,7 +83,12 @@
      *  canvas. The root device will have its top-left at 0,0, but other devices
      *  such as those associated with saveLayer may have a non-zero origin.
      */
-    virtual void getGlobalBounds(SkIRect* bounds) const = 0;
+    void getGlobalBounds(SkIRect* bounds) const {
+        SkASSERT(bounds);
+        const SkIPoint& origin = this->getOrigin();
+        bounds->setXYWH(origin.x(), origin.y(), this->width(), this->height());
+    }
+    
 
     /** Returns true if the device's bitmap's config treats every pixel as
         implicitly opaque.
@@ -383,6 +388,7 @@
     // used to change the backend's pixels (and possibly config/rowbytes)
     // but cannot change the width/height, so there should be no change to
     // any clip information.
+    // TODO: move to SkBitmapDevice
     virtual void replaceBitmapBackendForRasterSurface(const SkBitmap&) = 0;
 
     // just called by SkCanvas when built as a layer
diff --git a/gpu/SkGpuDevice.h b/gpu/SkGpuDevice.h
index 29f59f2..d37f63d 100644
--- a/gpu/SkGpuDevice.h
+++ b/gpu/SkGpuDevice.h
@@ -72,7 +72,6 @@
     virtual int height() const SK_OVERRIDE {
         return NULL == fRenderTarget ? 0 : fRenderTarget->height();
     }
-    virtual void getGlobalBounds(SkIRect* bounds) const SK_OVERRIDE;
     virtual bool isOpaque() const SK_OVERRIDE {
         return NULL == fRenderTarget ? false
                                      : kRGB_565_GrPixelConfig == fRenderTarget->config();