aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorGravatar scroggo <scroggo@google.com>2015-01-29 11:58:51 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2015-01-29 11:58:51 -0800
commit648238cc900994de79c9e7d17f755661222aa52f (patch)
tree165429a92dc26cf468de3f8cf392c63ea2d2a7e8 /src
parent65df6edf63c6b97ea81fb647c4ebd85729a750a2 (diff)
Remove SkProxyCanvas.
SkProxyCanvas is redundant with SkNWayCanvas, and means another class we have to keep in sync with the SkCanvas interface. Remove tests which use an SkProxyCanvas. Requires a change to chromium. BUG=skia:3279 BUG=skia:500 Review URL: https://codereview.chromium.org/886813002
Diffstat (limited to 'src')
-rw-r--r--src/utils/SkProxyCanvas.cpp186
1 files changed, 0 insertions, 186 deletions
diff --git a/src/utils/SkProxyCanvas.cpp b/src/utils/SkProxyCanvas.cpp
deleted file mode 100644
index ade4315f3d..0000000000
--- a/src/utils/SkProxyCanvas.cpp
+++ /dev/null
@@ -1,186 +0,0 @@
-
-/*
- * Copyright 2011 Google Inc.
- *
- * Use of this source code is governed by a BSD-style license that can be
- * found in the LICENSE file.
- */
-#include "SkProxyCanvas.h"
-
-SkProxyCanvas::SkProxyCanvas(SkCanvas* proxy) : fProxy(proxy) {
- SkSafeRef(fProxy);
-}
-
-SkProxyCanvas::~SkProxyCanvas() {
- SkSafeUnref(fProxy);
-}
-
-void SkProxyCanvas::setProxy(SkCanvas* proxy) {
- SkRefCnt_SafeAssign(fProxy, proxy);
-}
-
-///////////////////////////////// Overrides ///////////
-
-void SkProxyCanvas::willSave() {
- fProxy->save();
- this->INHERITED::willSave();
-}
-
-SkCanvas::SaveLayerStrategy SkProxyCanvas::willSaveLayer(const SkRect* bounds, const SkPaint* paint,
- SaveFlags flags) {
- fProxy->saveLayer(bounds, paint, flags);
- this->INHERITED::willSaveLayer(bounds, paint, flags);
- // No need for a layer.
- return kNoLayer_SaveLayerStrategy;
-}
-
-void SkProxyCanvas::willRestore() {
- fProxy->restore();
- this->INHERITED::willRestore();
-}
-
-void SkProxyCanvas::didConcat(const SkMatrix& matrix) {
- fProxy->concat(matrix);
- this->INHERITED::didConcat(matrix);
-}
-
-void SkProxyCanvas::didSetMatrix(const SkMatrix& matrix) {
- fProxy->setMatrix(matrix);
- this->INHERITED::didSetMatrix(matrix);
-}
-
-void SkProxyCanvas::onClipRect(const SkRect& rect, SkRegion::Op op, ClipEdgeStyle edgeStyle) {
- fProxy->clipRect(rect, op, kSoft_ClipEdgeStyle == edgeStyle);
-}
-
-void SkProxyCanvas::onClipRRect(const SkRRect& rrect, SkRegion::Op op, ClipEdgeStyle edgeStyle) {
- fProxy->clipRRect(rrect, op, kSoft_ClipEdgeStyle == edgeStyle);
-}
-
-void SkProxyCanvas::onClipPath(const SkPath& path, SkRegion::Op op, ClipEdgeStyle edgeStyle) {
- fProxy->clipPath(path, op, kSoft_ClipEdgeStyle == edgeStyle);
-}
-
-void SkProxyCanvas::onClipRegion(const SkRegion& deviceRgn, SkRegion::Op op) {
- fProxy->clipRegion(deviceRgn, op);
-}
-
-void SkProxyCanvas::onDrawPaint(const SkPaint& paint) {
- fProxy->drawPaint(paint);
-}
-
-void SkProxyCanvas::onDrawPoints(PointMode mode, size_t count,
- const SkPoint pts[], const SkPaint& paint) {
- fProxy->drawPoints(mode, count, pts, paint);
-}
-
-void SkProxyCanvas::onDrawOval(const SkRect& rect, const SkPaint& paint) {
- fProxy->drawOval(rect, paint);
-}
-
-void SkProxyCanvas::onDrawRect(const SkRect& rect, const SkPaint& paint) {
- fProxy->drawRect(rect, paint);
-}
-
-void SkProxyCanvas::onDrawRRect(const SkRRect& rrect, const SkPaint& paint) {
- fProxy->drawRRect(rrect, paint);
-}
-
-void SkProxyCanvas::onDrawDRRect(const SkRRect& outer, const SkRRect& inner,
- const SkPaint& paint) {
- fProxy->drawDRRect(outer, inner, paint);
-}
-
-void SkProxyCanvas::onDrawPath(const SkPath& path, const SkPaint& paint) {
- fProxy->drawPath(path, paint);
-}
-
-void SkProxyCanvas::onDrawImage(const SkImage* image, SkScalar left, SkScalar top,
- const SkPaint* paint) {
- fProxy->drawImage(image, left, top, paint);
-}
-
-void SkProxyCanvas::onDrawImageRect(const SkImage* image, const SkRect* src, const SkRect& dst,
- const SkPaint* paint) {
- fProxy->drawImageRect(image, src, dst, paint);
-}
-
-void SkProxyCanvas::onDrawBitmap(const SkBitmap& bitmap, SkScalar x, SkScalar y,
- const SkPaint* paint) {
- fProxy->drawBitmap(bitmap, x, y, paint);
-}
-
-void SkProxyCanvas::onDrawBitmapRect(const SkBitmap& bitmap, const SkRect* src, const SkRect& dst,
- const SkPaint* paint, DrawBitmapRectFlags flags) {
- fProxy->drawBitmapRectToRect(bitmap, src, dst, paint, flags);
-}
-
-void SkProxyCanvas::onDrawBitmapNine(const SkBitmap& bitmap, const SkIRect& center,
- const SkRect& dst, const SkPaint* paint) {
- fProxy->drawBitmapNine(bitmap, center, dst, paint);
-}
-
-void SkProxyCanvas::onDrawSprite(const SkBitmap& bitmap, int x, int y, const SkPaint* paint) {
- fProxy->drawSprite(bitmap, x, y, paint);
-}
-
-void SkProxyCanvas::onDrawText(const void* text, size_t byteLength, SkScalar x, SkScalar y,
- const SkPaint& paint) {
- fProxy->drawText(text, byteLength, x, y, paint);
-}
-
-void SkProxyCanvas::onDrawPosText(const void* text, size_t byteLength, const SkPoint pos[],
- const SkPaint& paint) {
- fProxy->drawPosText(text, byteLength, pos, paint);
-}
-
-void SkProxyCanvas::onDrawPosTextH(const void* text, size_t byteLength, const SkScalar xpos[],
- SkScalar constY, const SkPaint& paint) {
- fProxy->drawPosTextH(text, byteLength, xpos, constY, paint);
-}
-
-void SkProxyCanvas::onDrawTextOnPath(const void* text, size_t byteLength, const SkPath& path,
- const SkMatrix* matrix, const SkPaint& paint) {
- fProxy->drawTextOnPath(text, byteLength, path, matrix, paint);
-}
-
-void SkProxyCanvas::onDrawTextBlob(const SkTextBlob* blob, SkScalar x, SkScalar y,
- const SkPaint& paint) {
- fProxy->drawTextBlob(blob, x, y, paint);
-}
-
-void SkProxyCanvas::onDrawPicture(const SkPicture* picture, const SkMatrix* matrix,
- const SkPaint* paint) {
- fProxy->drawPicture(picture, matrix, paint);
-}
-
-void SkProxyCanvas::onDrawVertices(VertexMode vmode, int vertexCount,
- const SkPoint vertices[], const SkPoint texs[],
- const SkColor colors[], SkXfermode* xmode,
- const uint16_t indices[], int indexCount,
- const SkPaint& paint) {
- fProxy->drawVertices(vmode, vertexCount, vertices, texs, colors,
- xmode, indices, indexCount, paint);
-}
-
-void SkProxyCanvas::onDrawPatch(const SkPoint cubics[12], const SkColor colors[4],
- const SkPoint texCoords[4], SkXfermode* xmode,
- const SkPaint& paint) {
- fProxy->drawPatch(cubics, colors, texCoords, xmode, paint);
-}
-
-void SkProxyCanvas::beginCommentGroup(const char* description) {
- fProxy->beginCommentGroup(description);
-}
-
-void SkProxyCanvas::addComment(const char* kywd, const char* value) {
- fProxy->addComment(kywd, value);
-}
-
-void SkProxyCanvas::endCommentGroup() {
- fProxy->endCommentGroup();
-}
-
-SkDrawFilter* SkProxyCanvas::setDrawFilter(SkDrawFilter* filter) {
- return fProxy->setDrawFilter(filter);
-}