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

Unified Diff: third_party/WebKit/Source/modules/canvas/HTMLCanvasElementModule.cpp

Issue 2143033005: Transfer components of SurfaceId in OffscreenCanvas (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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/canvas/HTMLCanvasElementModule.cpp
diff --git a/third_party/WebKit/Source/modules/canvas/HTMLCanvasElementModule.cpp b/third_party/WebKit/Source/modules/canvas/HTMLCanvasElementModule.cpp
index 7119ec0471da0fe9edd446d70cd1586f478b6534..20ecce3b28f03f6527403f20e2a37b62ec7e73f7 100644
--- a/third_party/WebKit/Source/modules/canvas/HTMLCanvasElementModule.cpp
+++ b/third_party/WebKit/Source/modules/canvas/HTMLCanvasElementModule.cpp
@@ -37,6 +37,8 @@ OffscreenCanvas* HTMLCanvasElementModule::transferControlToOffscreenInternal(HTM
}
OffscreenCanvas* offscreenCanvas = OffscreenCanvas::create(canvas.width(), canvas.height());
offscreenCanvas->setAssociatedCanvasId(DOMNodeIds::idForNode(&canvas));
+ CanvasSurfaceLayerBridge* bridge = canvas.surfaceLayerBridge();
+ offscreenCanvas->setSurfaceId(bridge->getSurfaceId().client_id(), bridge->getSurfaceId().local_id(), bridge->getSurfaceId().nonce());
return offscreenCanvas;
}

Powered by Google App Engine
This is Rietveld 408576698