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

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

Issue 2050123002: Remove OwnPtr from Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: First attempt to land. Created 4 years, 6 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/WebGL2RenderingContext.cpp
diff --git a/third_party/WebKit/Source/modules/webgl/WebGL2RenderingContext.cpp b/third_party/WebKit/Source/modules/webgl/WebGL2RenderingContext.cpp
index 0f85d1114e2781cc350325863b4dd8dda02dab1c..a9ddea2fd78bdb879a3137a22bb8cd90e78169cc 100644
--- a/third_party/WebKit/Source/modules/webgl/WebGL2RenderingContext.cpp
+++ b/third_party/WebKit/Source/modules/webgl/WebGL2RenderingContext.cpp
@@ -28,6 +28,7 @@
#include "platform/graphics/gpu/DrawingBuffer.h"
#include "public/platform/Platform.h"
#include "public/platform/WebGraphicsContext3DProvider.h"
+#include <memory>
namespace blink {
@@ -39,11 +40,11 @@ CanvasRenderingContext* WebGL2RenderingContext::Factory::create(HTMLCanvasElemen
}
WebGLContextAttributes attributes = toWebGLContextAttributes(attrs);
- OwnPtr<WebGraphicsContext3DProvider> contextProvider(createWebGraphicsContext3DProvider(canvas, attributes, 2));
+ std::unique_ptr<WebGraphicsContext3DProvider> contextProvider(createWebGraphicsContext3DProvider(canvas, attributes, 2));
if (!contextProvider)
return nullptr;
gpu::gles2::GLES2Interface* gl = contextProvider->contextGL();
- OwnPtr<Extensions3DUtil> extensionsUtil = Extensions3DUtil::create(gl);
+ std::unique_ptr<Extensions3DUtil> extensionsUtil = Extensions3DUtil::create(gl);
if (!extensionsUtil)
return nullptr;
if (extensionsUtil->supportsExtension("GL_EXT_debug_marker")) {
@@ -69,7 +70,7 @@ void WebGL2RenderingContext::Factory::onError(HTMLCanvasElement* canvas, const S
canvas->dispatchEvent(WebGLContextEvent::create(EventTypeNames::webglcontextcreationerror, false, true, error));
}
-WebGL2RenderingContext::WebGL2RenderingContext(HTMLCanvasElement* passedCanvas, PassOwnPtr<WebGraphicsContext3DProvider> contextProvider, const WebGLContextAttributes& requestedAttributes)
+WebGL2RenderingContext::WebGL2RenderingContext(HTMLCanvasElement* passedCanvas, std::unique_ptr<WebGraphicsContext3DProvider> contextProvider, const WebGLContextAttributes& requestedAttributes)
: WebGL2RenderingContextBase(passedCanvas, std::move(contextProvider), requestedAttributes)
{
}

Powered by Google App Engine
This is Rietveld 408576698