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

Unified Diff: third_party/WebKit/Source/modules/webgl/WebGLRenderingContext.cpp

Issue 1979953002: Remove OwnPtr::release() calls in modules/ (part 3). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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/webgl/WebGLRenderingContext.cpp
diff --git a/third_party/WebKit/Source/modules/webgl/WebGLRenderingContext.cpp b/third_party/WebKit/Source/modules/webgl/WebGLRenderingContext.cpp
index 8307c0c43048ed02f93bbac8616785e9218a05b2..fe348e833d223cc86384101b2dc6e3047d1b21f8 100644
--- a/third_party/WebKit/Source/modules/webgl/WebGLRenderingContext.cpp
+++ b/third_party/WebKit/Source/modules/webgl/WebGLRenderingContext.cpp
@@ -89,7 +89,7 @@ CanvasRenderingContext* WebGLRenderingContext::Factory::create(ScriptState* scri
if (!shouldCreateContext(contextProvider.get()))
return nullptr;
- WebGLRenderingContext* renderingContext = new WebGLRenderingContext(offscreenCanvas, contextProvider.release(), attributes);
+ WebGLRenderingContext* renderingContext = new WebGLRenderingContext(offscreenCanvas, std::move(contextProvider), attributes);
if (!renderingContext->drawingBuffer())
return nullptr;
renderingContext->initializeNewContext();
@@ -105,7 +105,7 @@ CanvasRenderingContext* WebGLRenderingContext::Factory::create(HTMLCanvasElement
if (!shouldCreateContext(contextProvider.get()))
return nullptr;
- WebGLRenderingContext* renderingContext = new WebGLRenderingContext(canvas, contextProvider.release(), attributes);
+ WebGLRenderingContext* renderingContext = new WebGLRenderingContext(canvas, std::move(contextProvider), attributes);
if (!renderingContext->drawingBuffer()) {
canvas->dispatchEvent(WebGLContextEvent::create(EventTypeNames::webglcontextcreationerror, false, true, "Could not create a WebGL context."));
return nullptr;

Powered by Google App Engine
This is Rietveld 408576698