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

Unified Diff: third_party/WebKit/Source/platform/exported/WebFileSystemCallbacks.cpp

Issue 1916703002: Prepare for move-only PassOwnPtr in the remaining directories. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@core1
Patch Set: Merge with trunk. 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
Index: third_party/WebKit/Source/platform/exported/WebFileSystemCallbacks.cpp
diff --git a/third_party/WebKit/Source/platform/exported/WebFileSystemCallbacks.cpp b/third_party/WebKit/Source/platform/exported/WebFileSystemCallbacks.cpp
index d9cdbfa989f087ead14e7f74fdab6eac7e05f1b6..1a6053ec1c6d79353c3748f65fed3cea2e8da3d4 100644
--- a/third_party/WebKit/Source/platform/exported/WebFileSystemCallbacks.cpp
+++ b/third_party/WebKit/Source/platform/exported/WebFileSystemCallbacks.cpp
@@ -45,21 +45,21 @@ namespace blink {
class WebFileSystemCallbacksPrivate : public RefCounted<WebFileSystemCallbacksPrivate> {
public:
- static PassRefPtr<WebFileSystemCallbacksPrivate> create(const PassOwnPtr<AsyncFileSystemCallbacks>& callbacks)
+ static PassRefPtr<WebFileSystemCallbacksPrivate> create(PassOwnPtr<AsyncFileSystemCallbacks> callbacks)
{
- return adoptRef(new WebFileSystemCallbacksPrivate(callbacks));
+ return adoptRef(new WebFileSystemCallbacksPrivate(std::move(callbacks)));
}
AsyncFileSystemCallbacks* callbacks() { return m_callbacks.get(); }
private:
- WebFileSystemCallbacksPrivate(const PassOwnPtr<AsyncFileSystemCallbacks>& callbacks) : m_callbacks(callbacks) { }
+ WebFileSystemCallbacksPrivate(PassOwnPtr<AsyncFileSystemCallbacks> callbacks) : m_callbacks(std::move(callbacks)) { }
OwnPtr<AsyncFileSystemCallbacks> m_callbacks;
};
-WebFileSystemCallbacks::WebFileSystemCallbacks(const PassOwnPtr<AsyncFileSystemCallbacks>& callbacks)
+WebFileSystemCallbacks::WebFileSystemCallbacks(PassOwnPtr<AsyncFileSystemCallbacks>&& callbacks)
{
- m_private = WebFileSystemCallbacksPrivate::create(callbacks);
+ m_private = WebFileSystemCallbacksPrivate::create(std::move(callbacks));
}
void WebFileSystemCallbacks::reset()

Powered by Google App Engine
This is Rietveld 408576698