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

Unified Diff: third_party/WebKit/Source/modules/offscreencanvas/OffscreenCanvasModules.idl

Issue 2509193002: Correct the OffscreenCanvas.getContext API (Closed)
Patch Set: support webgl2 Created 4 years, 1 month 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/offscreencanvas/OffscreenCanvasModules.idl
diff --git a/third_party/WebKit/Source/modules/offscreencanvas/OffscreenCanvasModules.idl b/third_party/WebKit/Source/modules/offscreencanvas/OffscreenCanvasModules.idl
index 5a0b95bc411e64ac1a2f7ec2ab0b41ceba785639..f7af31e03e830c6e527c860b00333b9407c3e457 100644
--- a/third_party/WebKit/Source/modules/offscreencanvas/OffscreenCanvasModules.idl
+++ b/third_party/WebKit/Source/modules/offscreencanvas/OffscreenCanvasModules.idl
@@ -7,7 +7,8 @@
typedef (OffscreenCanvasRenderingContext2D or
WebGLRenderingContext or
WebGL2RenderingContext) OffscreenRenderingContext;
+enum OffscreenRenderingContextType { "2d", "webgl", "webgl2" };
partial interface OffscreenCanvas {
- [CallWith=ScriptState, RaisesException, RuntimeEnabled=ExperimentalCanvasFeatures] OffscreenRenderingContext? getContext(DOMString contextId, optional CanvasContextCreationAttributes attributes);
+ [CallWith=ScriptState, RaisesException, RuntimeEnabled=ExperimentalCanvasFeatures] OffscreenRenderingContext? getContext(OffscreenRenderingContextType contextType, optional CanvasContextCreationAttributes attributes);
};

Powered by Google App Engine
This is Rietveld 408576698