Chromium Code Reviews| Index: third_party/WebKit/Source/modules/offscreencanvas2d/OffscreenCanvasRenderingContext2D.cpp |
| diff --git a/third_party/WebKit/Source/modules/offscreencanvas2d/OffscreenCanvasRenderingContext2D.cpp b/third_party/WebKit/Source/modules/offscreencanvas2d/OffscreenCanvasRenderingContext2D.cpp |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..bcaec3ecf90cb13fe39ddc67697a02defa2ac8ba |
| --- /dev/null |
| +++ b/third_party/WebKit/Source/modules/offscreencanvas2d/OffscreenCanvasRenderingContext2D.cpp |
| @@ -0,0 +1,127 @@ |
| +// Copyright 2016 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#include "modules/offscreencanvas2d/OffscreenCanvasRenderingContext2D.h" |
| + |
| +#include "bindings/modules/v8/UnionTypesModules.h" |
| +#include "wtf/Assertions.h" |
| + |
| +#define UNIMPLEMENTED ASSERT_NOT_REACHED |
|
haraken
2016/03/04 16:22:15
Do you want to use platform/NotImplemented.h ?
|
| + |
| +namespace blink { |
| + |
| +OffscreenCanvasRenderingContext2D::~OffscreenCanvasRenderingContext2D() |
| +{ |
| +} |
| + |
| +OffscreenCanvasRenderingContext2D::OffscreenCanvasRenderingContext2D(OffscreenCanvas* canvas, const CanvasContextCreationAttributes& attrs) |
| + : OffscreenCanvasRenderingContext(canvas) |
| + , m_hasAlpha(attrs.alpha()) |
| +{ |
| +} |
| + |
| +DEFINE_TRACE(OffscreenCanvasRenderingContext2D) |
| +{ |
| + OffscreenCanvasRenderingContext::trace(visitor); |
| + BaseRenderingContext2D::trace(visitor); |
| +} |
| + |
| +// BaseRenderingContext2D implementation |
| +bool OffscreenCanvasRenderingContext2D::originClean() const |
| +{ |
| + UNIMPLEMENTED(); |
| + return true; |
| +} |
| + |
| +void OffscreenCanvasRenderingContext2D::setOriginTainted() |
| +{ |
| + UNIMPLEMENTED(); |
| +} |
| + |
| +bool OffscreenCanvasRenderingContext2D::wouldTaintOrigin(CanvasImageSource* source) |
| +{ |
| + UNIMPLEMENTED(); |
| + return false; |
| +} |
| + |
| +int OffscreenCanvasRenderingContext2D::width() const |
| +{ |
| + return offscreenCanvas()->height(); |
| +} |
| + |
| +int OffscreenCanvasRenderingContext2D::height() const |
| +{ |
| + return offscreenCanvas()->width(); |
| +} |
| + |
| +bool OffscreenCanvasRenderingContext2D::hasImageBuffer() const |
| +{ |
| + UNIMPLEMENTED(); |
| + return false; |
| +} |
| + |
| +ImageBuffer* OffscreenCanvasRenderingContext2D::imageBuffer() const |
| +{ |
| + UNIMPLEMENTED(); |
| + return nullptr; |
| +} |
| + |
| +bool OffscreenCanvasRenderingContext2D::parseColorOrCurrentColor(Color&, const String& colorString) const |
| +{ |
| + UNIMPLEMENTED(); |
| + return false; |
| +} |
| + |
| +SkCanvas* OffscreenCanvasRenderingContext2D::drawingCanvas() const |
| +{ |
| + UNIMPLEMENTED(); |
| + return nullptr; |
| +} |
| + |
| +SkCanvas* OffscreenCanvasRenderingContext2D::existingDrawingCanvas() const |
| +{ |
| + UNIMPLEMENTED(); |
| + return nullptr; |
| +} |
| + |
| +void OffscreenCanvasRenderingContext2D::disableDeferral(DisableDeferralReason) |
| +{ |
| + UNIMPLEMENTED(); |
| +} |
| + |
| +AffineTransform OffscreenCanvasRenderingContext2D::baseTransform() const |
| +{ |
| + UNIMPLEMENTED(); |
| + return 0; |
| +} |
| + |
| +void OffscreenCanvasRenderingContext2D::didDraw(const SkIRect& dirtyRect) |
| +{ |
| + UNIMPLEMENTED(); |
| +} |
| + |
| +bool OffscreenCanvasRenderingContext2D::stateHasFilter() |
| +{ |
| + UNIMPLEMENTED(); |
| + return false; |
| +} |
| + |
| +SkImageFilter* OffscreenCanvasRenderingContext2D::stateGetFilter() |
| +{ |
| + UNIMPLEMENTED(); |
| + return nullptr; |
| +} |
| + |
| +void OffscreenCanvasRenderingContext2D::validateStateStack() |
| +{ |
| + UNIMPLEMENTED(); |
| +} |
| + |
| +bool OffscreenCanvasRenderingContext2D::isContextLost() const |
| +{ |
| + UNIMPLEMENTED(); |
| + return false; |
| +} |
| + |
| +} |