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

Unified Diff: ui/ozone/platform/drm/gpu/gbm_buffer.cc

Issue 1528373002: Replace Pass() with std::move in ui/ozone (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add #include <utility> Created 5 years 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/drm/gpu/drm_window_unittest.cc ('k') | ui/ozone/platform/drm/gpu/gbm_device.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/ozone/platform/drm/gpu/gbm_buffer.cc
diff --git a/ui/ozone/platform/drm/gpu/gbm_buffer.cc b/ui/ozone/platform/drm/gpu/gbm_buffer.cc
index 34570f0e9ea358bae9ecfdacdbc4f31e5ffb6732..567f5d91699ae54690caa7a37ce64f7d70057128 100644
--- a/ui/ozone/platform/drm/gpu/gbm_buffer.cc
+++ b/ui/ozone/platform/drm/gpu/gbm_buffer.cc
@@ -8,6 +8,7 @@
#include <fcntl.h>
#include <gbm.h>
#include <xf86drm.h>
+#include <utility>
#include "base/logging.h"
#include "base/posix/eintr_wrapper.h"
@@ -69,7 +70,7 @@ GbmPixmap::GbmPixmap(GbmSurfaceFactory* surface_manager)
: surface_manager_(surface_manager) {}
void GbmPixmap::Initialize(base::ScopedFD dma_buf, int dma_buf_pitch) {
- dma_buf_ = dma_buf.Pass();
+ dma_buf_ = std::move(dma_buf);
dma_buf_pitch_ = dma_buf_pitch;
}
@@ -82,7 +83,7 @@ bool GbmPixmap::InitializeFromBuffer(const scoped_refptr<GbmBuffer>& buffer) {
PLOG(ERROR) << "Failed to export buffer to dma_buf";
return false;
}
- Initialize(dma_buf.Pass(), gbm_bo_get_stride(buffer->bo()));
+ Initialize(std::move(dma_buf), gbm_bo_get_stride(buffer->bo()));
buffer_ = buffer;
return true;
}
« no previous file with comments | « ui/ozone/platform/drm/gpu/drm_window_unittest.cc ('k') | ui/ozone/platform/drm/gpu/gbm_device.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698