aboutsummaryrefslogtreecommitdiffhomepage
path: root/experimental
diff options
context:
space:
mode:
Diffstat (limited to 'experimental')
-rw-r--r--experimental/PdfViewer/SkNulCanvas.h4
-rw-r--r--experimental/PdfViewer/SkPdfRenderer.cpp4
-rw-r--r--experimental/PdfViewer/SkTrackDevice.h14
-rw-r--r--experimental/PdfViewer/pdf_viewer_main.cpp6
-rw-r--r--experimental/SkiaExamples/SkExample.cpp2
-rw-r--r--experimental/iOSSampleApp/SkSampleUIView.mm4
6 files changed, 17 insertions, 17 deletions
diff --git a/experimental/PdfViewer/SkNulCanvas.h b/experimental/PdfViewer/SkNulCanvas.h
index 98d958397a..1789b6f513 100644
--- a/experimental/PdfViewer/SkNulCanvas.h
+++ b/experimental/PdfViewer/SkNulCanvas.h
@@ -15,7 +15,7 @@ public:
SK_DECLARE_INST_COUNT(SkNulCanvas);
SkNulCanvas() {}
- explicit SkNulCanvas(SkDevice* device) : SkCanvas(device) {}
+ explicit SkNulCanvas(SkBaseDevice* device) : SkCanvas(device) {}
explicit SkNulCanvas(const SkBitmap& bitmap) : SkCanvas(bitmap) {}
virtual ~SkNulCanvas() {}
@@ -90,7 +90,7 @@ public:
protected:
virtual SkCanvas* canvasForDrawIter() {return NULL;}
- virtual SkDevice* setDevice(SkDevice* device) {return NULL;}
+ virtual SkBaseDevice* setDevice(SkBaseDevice* device) {return NULL;}
private:
typedef SkCanvas INHERITED;
diff --git a/experimental/PdfViewer/SkPdfRenderer.cpp b/experimental/PdfViewer/SkPdfRenderer.cpp
index 7fa1c1502e..57b41c8912 100644
--- a/experimental/PdfViewer/SkPdfRenderer.cpp
+++ b/experimental/PdfViewer/SkPdfRenderer.cpp
@@ -352,7 +352,7 @@ static bool readToken(SkPdfNativeTokenizer* fTokenizer, PdfToken* token) {
memcpy(bitmap.getPixels(), gDumpBitmap->getPixels(), gDumpBitmap->getSize());
- SkAutoTUnref<SkDevice> device(SkNEW_ARGS(SkDevice, (bitmap)));
+ SkAutoTUnref<SkBaseDevice> device(SkNEW_ARGS(SkBitmapDevice, (bitmap)));
SkCanvas canvas(device);
// draw context stuff here
@@ -2909,7 +2909,7 @@ bool SkPDFNativeRenderToBitmap(SkStream* stream,
setup_bitmap(output, (int)SkScalarToDouble(width), (int)SkScalarToDouble(height));
- SkAutoTUnref<SkDevice> device(SkNEW_ARGS(SkDevice, (*output)));
+ SkAutoTUnref<SkBaseDevice> device(SkNEW_ARGS(SkBitmapDevice, (*output)));
SkCanvas canvas(device);
return renderer.renderPage(page, &canvas, rect);
diff --git a/experimental/PdfViewer/SkTrackDevice.h b/experimental/PdfViewer/SkTrackDevice.h
index 545250b8e7..2b8a8eab2d 100644
--- a/experimental/PdfViewer/SkTrackDevice.h
+++ b/experimental/PdfViewer/SkTrackDevice.h
@@ -11,24 +11,24 @@
#include "SkDevice.h"
#include "SkTracker.h"
-class SkTrackDevice : public SkDevice {
+class SkTrackDevice : public SkBitmapDevice {
public:
SK_DECLARE_INST_COUNT(SkTrackDevice)
- SkTrackDevice(const SkBitmap& bitmap) : SkDevice(bitmap)
+ SkTrackDevice(const SkBitmap& bitmap) : SkBitmapDevice(bitmap)
, fTracker(NULL) {}
SkTrackDevice(const SkBitmap& bitmap, const SkDeviceProperties& deviceProperties)
- : SkDevice(bitmap, deviceProperties)
+ : SkBitmapDevice(bitmap, deviceProperties)
, fTracker(NULL) {}
SkTrackDevice(SkBitmap::Config config, int width, int height, bool isOpaque = false)
- : SkDevice(config, width, height, isOpaque)
+ : SkBitmapDevice(config, width, height, isOpaque)
, fTracker(NULL) {}
SkTrackDevice(SkBitmap::Config config, int width, int height, bool isOpaque,
const SkDeviceProperties& deviceProperties)
- : SkDevice(config, width, height, isOpaque, deviceProperties)
+ : SkBitmapDevice(config, width, height, isOpaque, deviceProperties)
, fTracker(NULL) {}
virtual ~SkTrackDevice() {}
@@ -154,7 +154,7 @@ protected:
after();
}
- virtual void drawDevice(const SkDraw& dummy1, SkDevice* dummy2, int x, int y,
+ virtual void drawDevice(const SkDraw& dummy1, SkBaseDevice* dummy2, int x, int y,
const SkPaint& dummy3) {
before();
INHERITED::drawDevice(dummy1, dummy2, x, y, dummy3);
@@ -178,7 +178,7 @@ private:
private:
SkTracker* fTracker;
- typedef SkDevice INHERITED;
+ typedef SkBitmapDevice INHERITED;
};
#endif // SkTrackDevice_DEFINED
diff --git a/experimental/PdfViewer/pdf_viewer_main.cpp b/experimental/PdfViewer/pdf_viewer_main.cpp
index ca2a9daf6e..5fe99ad180 100644
--- a/experimental/PdfViewer/pdf_viewer_main.cpp
+++ b/experimental/PdfViewer/pdf_viewer_main.cpp
@@ -186,7 +186,7 @@ static bool render_page(const SkString& outputDir,
// Exercise all pdf codepaths as in normal rendering, but no actual bits are changed.
if (!FLAGS_config.isEmpty() && strcmp(FLAGS_config[0], "nul") == 0) {
SkBitmap bitmap;
- SkAutoTUnref<SkDevice> device(SkNEW_ARGS(SkDevice, (bitmap)));
+ SkAutoTUnref<SkBaseDevice> device(SkNEW_ARGS(SkBitmapDevice, (bitmap)));
SkNulCanvas canvas(device);
renderer.renderPage(page < 0 ? 0 : page, &canvas, rect);
} else {
@@ -204,9 +204,9 @@ static bool render_page(const SkString& outputDir,
#else
setup_bitmap(&bitmap, (int)SkScalarToDouble(width), (int)SkScalarToDouble(height));
#endif
- SkAutoTUnref<SkDevice> device;
+ SkAutoTUnref<SkBaseDevice> device;
if (strcmp(FLAGS_config[0], "8888") == 0) {
- device.reset(SkNEW_ARGS(SkDevice, (bitmap)));
+ device.reset(SkNEW_ARGS(SkBitmapDevice, (bitmap)));
}
#if SK_SUPPORT_GPU
else if (strcmp(FLAGS_config[0], "gpu") == 0) {
diff --git a/experimental/SkiaExamples/SkExample.cpp b/experimental/SkiaExamples/SkExample.cpp
index 387276ad1b..d3601e1cac 100644
--- a/experimental/SkiaExamples/SkExample.cpp
+++ b/experimental/SkiaExamples/SkExample.cpp
@@ -115,7 +115,7 @@ void SkExampleWindow::setupRenderTarget() {
SkCanvas* SkExampleWindow::createCanvas() {
if (fType == kGPU_DeviceType) {
if (NULL != fContext && NULL != fRenderTarget) {
- SkAutoTUnref<SkDevice> device(new SkGpuDevice(fContext, fRenderTarget));
+ SkAutoTUnref<SkBaseDevice> device(new SkGpuDevice(fContext, fRenderTarget));
return new SkCanvas(device);
}
tearDownBackend();
diff --git a/experimental/iOSSampleApp/SkSampleUIView.mm b/experimental/iOSSampleApp/SkSampleUIView.mm
index 9fc95bd152..421dfcf275 100644
--- a/experimental/iOSSampleApp/SkSampleUIView.mm
+++ b/experimental/iOSSampleApp/SkSampleUIView.mm
@@ -136,8 +136,8 @@ public:
case SampleWindow::kGPU_DeviceType:
case SampleWindow::kNullGPU_DeviceType:
if (fCurContext) {
- SkAutoTUnref<SkDevice> device(new SkGpuDevice(fCurContext,
- fCurRenderTarget));
+ SkAutoTUnref<SkBaseDevice> device(new SkGpuDevice(fCurContext,
+ fCurRenderTarget));
return new SkCanvas(device);
} else {
return NULL;