Make SkPDFDevice::setOrigin accessible to Chrome's VectorPlatformDeviceSkia.
BUG=chrome 82746
Review URL: http://codereview.appspot.com/4888048
git-svn-id: http://skia.googlecode.com/svn/trunk@2116 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/include/pdf/SkPDFDevice.h b/include/pdf/SkPDFDevice.h
index 4bea1c2..9892d5c 100644
--- a/include/pdf/SkPDFDevice.h
+++ b/include/pdf/SkPDFDevice.h
@@ -167,7 +167,12 @@
return *(fFontGlyphUsage.get());
}
+ // TODO(vandebo) Remove this as soon as Chrome's Platform device goes away.
+ void setOrigin(int x, int y);
+
private:
+ typedef SkDevice INHERITED;
+
// TODO(vandebo) push most of SkPDFDevice's state into a core object in
// order to get the right access levels without using friend.
friend class ScopedContentEntry;
diff --git a/src/pdf/SkPDFDevice.cpp b/src/pdf/SkPDFDevice.cpp
index f5482cd..daf8018 100644
--- a/src/pdf/SkPDFDevice.cpp
+++ b/src/pdf/SkPDFDevice.cpp
@@ -1158,6 +1158,10 @@
return data.copyToData();
}
+void SkPDFDevice::setOrigin(int x, int y) {
+ INHERITED::setOrigin(x, y);
+}
+
void SkPDFDevice::createFormXObjectFromDevice(
SkRefPtr<SkPDFFormXObject>* xobject) {
*xobject = new SkPDFFormXObject(this);