Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(975)

Unified Diff: third_party/WebKit/Source/modules/imagebitmap/ImageBitmapRenderingContext.cpp

Issue 1761003003: Use a union typdef for the return type of canvas.getContext (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: final touches Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/modules/imagebitmap/ImageBitmapRenderingContext.cpp
diff --git a/third_party/WebKit/Source/modules/imagebitmap/ImageBitmapRenderingContext.cpp b/third_party/WebKit/Source/modules/imagebitmap/ImageBitmapRenderingContext.cpp
index bc5612619ee910980c9c740422295a099f78f112..7acc62917eef6850a797e8fa0322968a93264956 100644
--- a/third_party/WebKit/Source/modules/imagebitmap/ImageBitmapRenderingContext.cpp
+++ b/third_party/WebKit/Source/modules/imagebitmap/ImageBitmapRenderingContext.cpp
@@ -4,6 +4,7 @@
#include "modules/imagebitmap/ImageBitmapRenderingContext.h"
+#include "bindings/modules/v8/UnionTypesModules.h"
#include "core/frame/ImageBitmap.h"
#include "platform/graphics/GraphicsContext.h"
#include "platform/graphics/StaticBitmapImage.h"
@@ -19,6 +20,11 @@ ImageBitmapRenderingContext::ImageBitmapRenderingContext(HTMLCanvasElement* canv
ImageBitmapRenderingContext::~ImageBitmapRenderingContext() { }
+void ImageBitmapRenderingContext::setCanvasGetContextResult(RenderingContext& result)
+{
+ result.setImageBitmapRenderingContext(PassRefPtrWillBeRawPtr<ImageBitmapRenderingContext>(this));
+}
+
void ImageBitmapRenderingContext::transferImageBitmap(ImageBitmap* imageBitmap)
{
m_image = imageBitmap->bitmapImage();

Powered by Google App Engine
This is Rietveld 408576698