Index: Source/core/html/canvas/CanvasRenderingContext2D.cpp |
diff --git a/Source/core/html/canvas/CanvasRenderingContext2D.cpp b/Source/core/html/canvas/CanvasRenderingContext2D.cpp |
index 5adbd20c4097e9c2e9c11f357fa3f9e6ce90d94d..fa06fb6c7fd360cb6c68f7a9e3931c09964e9563 100644 |
--- a/Source/core/html/canvas/CanvasRenderingContext2D.cpp |
+++ b/Source/core/html/canvas/CanvasRenderingContext2D.cpp |
@@ -1667,9 +1667,9 @@ GraphicsContext* CanvasRenderingContext2D::drawingContext() const |
return canvas()->drawingContext(); |
} |
-static PassRefPtr<ImageData> createEmptyImageData(const IntSize& size) |
+static PassRefPtrWillBeRawPtr<ImageData> createEmptyImageData(const IntSize& size) |
{ |
- if (RefPtr<ImageData> data = ImageData::create(size)) { |
+ if (RefPtrWillBeRawPtr<ImageData> data = ImageData::create(size)) { |
data->data()->zeroFill(); |
return data.release(); |
} |
@@ -1677,7 +1677,7 @@ static PassRefPtr<ImageData> createEmptyImageData(const IntSize& size) |
return nullptr; |
} |
-PassRefPtr<ImageData> CanvasRenderingContext2D::createImageData(PassRefPtr<ImageData> imageData, ExceptionState& exceptionState) const |
+PassRefPtrWillBeRawPtr<ImageData> CanvasRenderingContext2D::createImageData(PassRefPtrWillBeRawPtr<ImageData> imageData, ExceptionState& exceptionState) const |
{ |
if (!imageData) { |
exceptionState.throwDOMException(NotSupportedError, ExceptionMessages::argumentNullOrIncorrectType(1, "ImageData")); |
@@ -1687,7 +1687,7 @@ PassRefPtr<ImageData> CanvasRenderingContext2D::createImageData(PassRefPtr<Image |
return createEmptyImageData(imageData->size()); |
} |
-PassRefPtr<ImageData> CanvasRenderingContext2D::createImageData(float sw, float sh, ExceptionState& exceptionState) const |
+PassRefPtrWillBeRawPtr<ImageData> CanvasRenderingContext2D::createImageData(float sw, float sh, ExceptionState& exceptionState) const |
{ |
if (!sw || !sh) |
exceptionState.throwDOMException(IndexSizeError, String::format("The source %s is 0.", sw ? "height" : "width")); |
@@ -1712,7 +1712,7 @@ PassRefPtr<ImageData> CanvasRenderingContext2D::createImageData(float sw, float |
return createEmptyImageData(size); |
} |
-PassRefPtr<ImageData> CanvasRenderingContext2D::getImageData(float sx, float sy, float sw, float sh, ExceptionState& exceptionState) const |
+PassRefPtrWillBeRawPtr<ImageData> CanvasRenderingContext2D::getImageData(float sx, float sy, float sw, float sh, ExceptionState& exceptionState) const |
{ |
if (!canvas()->originClean()) |
exceptionState.throwSecurityError("The canvas has been tainted by cross-origin data."); |