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

Unified Diff: third_party/WebKit/Source/core/html/canvas/CanvasRenderingContext.cpp

Issue 1598923002: Add ImageBitmapRenderingContext (experimental) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: another missing adoptRef Created 4 years, 10 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/core/html/canvas/CanvasRenderingContext.cpp
diff --git a/third_party/WebKit/Source/core/html/canvas/CanvasRenderingContext.cpp b/third_party/WebKit/Source/core/html/canvas/CanvasRenderingContext.cpp
index 214e2d25363f92b0efe82842f800dbe4df4f6f60..f89f167b26864c2ca3600ad1cf52096574df7155 100644
--- a/third_party/WebKit/Source/core/html/canvas/CanvasRenderingContext.cpp
+++ b/third_party/WebKit/Source/core/html/canvas/CanvasRenderingContext.cpp
@@ -26,6 +26,7 @@
#include "core/html/canvas/CanvasRenderingContext.h"
#include "core/html/canvas/CanvasImageSource.h"
+#include "platform/RuntimeEnabledFeatures.h"
#include "platform/weborigin/SecurityOrigin.h"
namespace blink {
@@ -45,7 +46,9 @@ CanvasRenderingContext::ContextType CanvasRenderingContext::contextTypeFromId(co
return ContextWebgl;
if (id == "webgl2")
return ContextWebgl2;
-
+ if (id == "imagebitmap" && RuntimeEnabledFeatures::experimentalCanvasFeaturesEnabled()) {
+ return ContextImageBitmap;
+ }
return ContextTypeCount;
}
« no previous file with comments | « third_party/WebKit/Source/core/html/canvas/CanvasRenderingContext.h ('k') | third_party/WebKit/Source/modules/InitModules.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698