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

Unified Diff: content/browser/web_contents/aura/overscroll_navigation_overlay_unittest.cc

Issue 1545243002: Convert Pass()→std::move() in //content/browser (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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
Index: content/browser/web_contents/aura/overscroll_navigation_overlay_unittest.cc
diff --git a/content/browser/web_contents/aura/overscroll_navigation_overlay_unittest.cc b/content/browser/web_contents/aura/overscroll_navigation_overlay_unittest.cc
index 4c8eea2e1c464498efa6c7cb9e749eed104de4bb..97dd750160c48838de78b3654247530be7afe989 100644
--- a/content/browser/web_contents/aura/overscroll_navigation_overlay_unittest.cc
+++ b/content/browser/web_contents/aura/overscroll_navigation_overlay_unittest.cc
@@ -5,7 +5,7 @@
#include "content/browser/web_contents/aura/overscroll_navigation_overlay.h"
#include <string.h>
-
+#include <utility>
#include <vector>
#include "base/macros.h"
@@ -42,7 +42,8 @@ class OverscrollTestWebContents : public TestWebContents {
scoped_ptr<aura::Window> fake_native_view,
scoped_ptr<aura::Window> fake_contents_window) {
OverscrollTestWebContents* web_contents = new OverscrollTestWebContents(
- browser_context, fake_native_view.Pass(), fake_contents_window.Pass());
+ browser_context, std::move(fake_native_view),
+ std::move(fake_contents_window));
web_contents->Init(WebContents::CreateParams(browser_context, instance));
return web_contents;
}
@@ -67,8 +68,8 @@ class OverscrollTestWebContents : public TestWebContents {
scoped_ptr<aura::Window> fake_native_view,
scoped_ptr<aura::Window> fake_contents_window)
: TestWebContents(browser_context),
- fake_native_view_(fake_native_view.Pass()),
- fake_contents_window_(fake_contents_window.Pass()),
+ fake_native_view_(std::move(fake_native_view)),
+ fake_contents_window_(std::move(fake_contents_window)),
is_being_destroyed_(false) {}
private:
@@ -120,7 +121,7 @@ class OverscrollNavigationOverlayTest : public RenderViewHostImplTestHarness {
else
EXPECT_EQ(GetOverlay()->direction_, OverscrollNavigationOverlay::NONE);
window->SetBounds(gfx::Rect(root_window()->bounds().size()));
- GetOverlay()->OnOverscrollCompleted(window.Pass());
+ GetOverlay()->OnOverscrollCompleted(std::move(window));
if (IsBrowserSideNavigationEnabled())
main_test_rfh()->PrepareForCommit();
else
@@ -166,10 +167,8 @@ class OverscrollNavigationOverlayTest : public RenderViewHostImplTestHarness {
// Replace the default test web contents with our custom class.
SetContents(OverscrollTestWebContents::Create(
- browser_context(),
- SiteInstance::Create(browser_context()),
- fake_native_view.Pass(),
- fake_contents_window.Pass()));
+ browser_context(), SiteInstance::Create(browser_context()),
+ std::move(fake_native_view), std::move(fake_contents_window)));
contents()->NavigateAndCommit(first());
EXPECT_TRUE(controller().GetVisibleEntry());

Powered by Google App Engine
This is Rietveld 408576698