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

Unified Diff: ui/ozone/platform/wayland/fake_server.cc

Issue 1868363002: Replace scoped_ptr with std::unique_ptr in //ui (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@scopedptrcc
Patch Set: scopedptrui: rebase-make_scoped_ptr 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 | « ui/ozone/platform/wayland/fake_server.h ('k') | ui/ozone/platform/wayland/ozone_platform_wayland.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/ozone/platform/wayland/fake_server.cc
diff --git a/ui/ozone/platform/wayland/fake_server.cc b/ui/ozone/platform/wayland/fake_server.cc
index 0465728b1b20ae3a7be2c4f54c7d609181dead67..03704a94d049c1a42dda143f8248e595858cb0e1 100644
--- a/ui/ozone/platform/wayland/fake_server.cc
+++ b/ui/ozone/platform/wayland/fake_server.cc
@@ -10,6 +10,7 @@
#include "base/bind.h"
#include "base/files/scoped_file.h"
+#include "base/memory/ptr_util.h"
#include "base/run_loop.h"
#include "base/strings/string_number_conversions.h"
@@ -35,7 +36,7 @@ void CreateSurface(wl_client* client, wl_resource* resource, uint32_t id) {
wl_client_post_no_memory(client);
return;
}
- compositor->AddSurface(make_scoped_ptr(new MockSurface(surface_resource)));
+ compositor->AddSurface(base::WrapUnique(new MockSurface(surface_resource)));
}
const struct wl_compositor_interface compositor_impl = {
@@ -291,7 +292,7 @@ MockCompositor::MockCompositor()
MockCompositor::~MockCompositor() {}
-void MockCompositor::AddSurface(scoped_ptr<MockSurface> surface) {
+void MockCompositor::AddSurface(std::unique_ptr<MockSurface> surface) {
surfaces_.push_back(std::move(surface));
}
@@ -373,8 +374,8 @@ void FakeServer::DoPause() {
resume_event_.Wait();
}
-scoped_ptr<base::MessagePump> FakeServer::CreateMessagePump() {
- auto pump = make_scoped_ptr(new base::MessagePumpLibevent);
+std::unique_ptr<base::MessagePump> FakeServer::CreateMessagePump() {
+ auto pump = base::WrapUnique(new base::MessagePumpLibevent);
pump->WatchFileDescriptor(wl_event_loop_get_fd(event_loop_), true,
base::MessagePumpLibevent::WATCH_READ, &controller_,
this);
« no previous file with comments | « ui/ozone/platform/wayland/fake_server.h ('k') | ui/ozone/platform/wayland/ozone_platform_wayland.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698