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

Unified Diff: ash/shelf/shelf_view_unittest.cc

Issue 1547223002: Convert Pass()→std::move() in //ash (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
« no previous file with comments | « ash/shelf/shelf_unittest.cc ('k') | ash/shelf/shelf_window_watcher.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/shelf/shelf_view_unittest.cc
diff --git a/ash/shelf/shelf_view_unittest.cc b/ash/shelf/shelf_view_unittest.cc
index 203048e74042988d050421e0a7faaba22d30647b..efd75ad6fddc47fa91207e4923e4d68352ee2fe5 100644
--- a/ash/shelf/shelf_view_unittest.cc
+++ b/ash/shelf/shelf_view_unittest.cc
@@ -333,7 +333,7 @@ class ShelfViewTest : public AshTestBase {
protected:
void CreateAndSetShelfItemDelegateForID(ShelfID id) {
scoped_ptr<ShelfItemDelegate> delegate(new TestShelfItemDelegate(NULL));
- item_manager_->SetShelfItemDelegate(id, delegate.Pass());
+ item_manager_->SetShelfItemDelegate(id, std::move(delegate));
}
ShelfID AddBrowserShortcut() {
@@ -1241,8 +1241,7 @@ TEST_F(ShelfViewTest, ClickingTwiceActivatesOnce) {
ShelfID browser_shelf_id = model_->items()[browser_index_].id;
ShelfItemSelectionTracker* selection_tracker = new ShelfItemSelectionTracker;
item_manager_->SetShelfItemDelegate(
- browser_shelf_id,
- scoped_ptr<ShelfItemDelegate>(selection_tracker).Pass());
+ browser_shelf_id, scoped_ptr<ShelfItemDelegate>(selection_tracker));
// A single click selects the item.
SimulateClick(browser_index_);
@@ -1267,8 +1266,7 @@ TEST_F(ShelfViewTest, ClickAndMoveSlightly) {
// the shelf item gets selected.
ShelfItemSelectionTracker* selection_tracker = new ShelfItemSelectionTracker;
item_manager_->SetShelfItemDelegate(
- shelf_id,
- scoped_ptr<ShelfItemDelegate>(selection_tracker).Pass());
+ shelf_id, scoped_ptr<ShelfItemDelegate>(selection_tracker));
gfx::Vector2d press_offset(5, 30);
gfx::Point press_location = gfx::Point() + press_offset;
@@ -1874,8 +1872,7 @@ TEST_F(ShelfViewTest,
ShelfID browser_shelf_id = model_->items()[browser_index_].id;
ShelfItemSelectionTracker* selection_tracker = new ShelfItemSelectionTracker;
item_manager_->SetShelfItemDelegate(
- browser_shelf_id,
- scoped_ptr<ShelfItemDelegate>(selection_tracker).Pass());
+ browser_shelf_id, scoped_ptr<ShelfItemDelegate>(selection_tracker));
SimulateClick(browser_index_);
EXPECT_EQ(1,
@@ -1892,8 +1889,7 @@ TEST_F(ShelfViewTest, Launcher_TaskUserActionsRecordedWhenItemSelected) {
selection_tracker->set_item_selected_action(
ShelfItemDelegate::kNewWindowCreated);
item_manager_->SetShelfItemDelegate(
- browser_shelf_id,
- scoped_ptr<ShelfItemDelegate>(selection_tracker).Pass());
+ browser_shelf_id, scoped_ptr<ShelfItemDelegate>(selection_tracker));
SimulateClick(browser_index_);
EXPECT_EQ(1, user_action_tester.GetActionCount("Launcher_LaunchTask"));
@@ -1908,8 +1904,7 @@ TEST_F(ShelfViewTest,
ShelfID browser_shelf_id = model_->items()[browser_index_].id;
ShelfItemSelectionTracker* selection_tracker = new ShelfItemSelectionTracker;
item_manager_->SetShelfItemDelegate(
- browser_shelf_id,
- scoped_ptr<ShelfItemDelegate>(selection_tracker).Pass());
+ browser_shelf_id, scoped_ptr<ShelfItemDelegate>(selection_tracker));
selection_tracker->set_item_selected_action(
ShelfItemDelegate::kExistingWindowMinimized);
« no previous file with comments | « ash/shelf/shelf_unittest.cc ('k') | ash/shelf/shelf_window_watcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698