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

Unified Diff: cc/test/test_context_provider.h

Issue 1866203004: Convert //cc from scoped_ptr to std::unique_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: scopedptrcc: rebase Created 4 years, 8 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
« no previous file with comments | « cc/test/surface_hittest_test_helpers.cc ('k') | cc/test/test_context_provider.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/test_context_provider.h
diff --git a/cc/test/test_context_provider.h b/cc/test/test_context_provider.h
index b0ac88eadc1dd3801b2789b65112558aa443548b..99d15c8b30dc05ae1f22e0fb2b5b168fb05cca48 100644
--- a/cc/test/test_context_provider.h
+++ b/cc/test/test_context_provider.h
@@ -8,9 +8,10 @@
#include <stddef.h>
#include <stdint.h>
+#include <memory>
+
#include "base/callback.h"
#include "base/macros.h"
-#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/synchronization/lock.h"
#include "base/threading/thread_checker.h"
@@ -25,15 +26,15 @@ class TestGLES2Interface;
class TestContextProvider : public ContextProvider {
public:
- typedef base::Callback<scoped_ptr<TestWebGraphicsContext3D>(void)>
- CreateCallback;
+ typedef base::Callback<std::unique_ptr<TestWebGraphicsContext3D>(void)>
+ CreateCallback;
static scoped_refptr<TestContextProvider> Create();
// Creates a worker context provider that can be used on any thread. This is
// equivalent to: Create(); BindToCurrentThread(); SetupLock().
static scoped_refptr<TestContextProvider> CreateWorker();
static scoped_refptr<TestContextProvider> Create(
- scoped_ptr<TestWebGraphicsContext3D> context);
+ std::unique_ptr<TestWebGraphicsContext3D> context);
bool BindToCurrentThread() override;
void DetachFromThread() override;
@@ -60,7 +61,8 @@ class TestContextProvider : public ContextProvider {
void SetMaxTransferBufferUsageBytes(size_t max_transfer_buffer_usage_bytes);
protected:
- explicit TestContextProvider(scoped_ptr<TestWebGraphicsContext3D> context);
+ explicit TestContextProvider(
+ std::unique_ptr<TestWebGraphicsContext3D> context);
~TestContextProvider() override;
private:
@@ -68,8 +70,8 @@ class TestContextProvider : public ContextProvider {
TestContextSupport support_;
- scoped_ptr<TestWebGraphicsContext3D> context3d_;
- scoped_ptr<TestGLES2Interface> context_gl_;
+ std::unique_ptr<TestWebGraphicsContext3D> context3d_;
+ std::unique_ptr<TestGLES2Interface> context_gl_;
bool bound_;
base::ThreadChecker main_thread_checker_;
« no previous file with comments | « cc/test/surface_hittest_test_helpers.cc ('k') | cc/test/test_context_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698