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

Unified Diff: ui/app_list/test/app_list_test_model.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/app_list/shower/app_list_shower_impl_unittest.cc ('k') | ui/app_list/test/app_list_test_view_delegate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/app_list/test/app_list_test_model.cc
diff --git a/ui/app_list/test/app_list_test_model.cc b/ui/app_list/test/app_list_test_model.cc
index 801ff65ed5a5575c49529d1a4b1c1aed2d79c316..024f90c14470a4fe5a29dd8e85df41de15d4a149 100644
--- a/ui/app_list/test/app_list_test_model.cc
+++ b/ui/app_list/test/app_list_test_model.cc
@@ -6,9 +6,10 @@
#include <stddef.h>
+#include <memory>
#include <utility>
-#include "base/memory/scoped_ptr.h"
+#include "base/memory/ptr_util.h"
#include "base/strings/stringprintf.h"
#include "third_party/skia/include/core/SkBitmap.h"
#include "ui/app_list/app_list_constants.h"
@@ -61,12 +62,12 @@ AppListTestModel::AppListTestModel()
}
AppListItem* AppListTestModel::AddItem(AppListItem* item) {
- return AppListModel::AddItem(make_scoped_ptr(item));
+ return AppListModel::AddItem(base::WrapUnique(item));
}
AppListItem* AppListTestModel::AddItemToFolder(AppListItem* item,
const std::string& folder_id) {
- return AppListModel::AddItemToFolder(make_scoped_ptr(item), folder_id);
+ return AppListModel::AddItemToFolder(base::WrapUnique(item), folder_id);
}
void AppListTestModel::MoveItemToFolder(AppListItem* item,
@@ -148,7 +149,7 @@ AppListTestModel::AppListTestItem* AppListTestModel::CreateItem(
AppListTestModel::AppListTestItem* AppListTestModel::CreateAndAddItem(
const std::string& id) {
- scoped_ptr<AppListTestItem> test_item(CreateItem(id));
+ std::unique_ptr<AppListTestItem> test_item(CreateItem(id));
AppListItem* item = AppListModel::AddItem(std::move(test_item));
return static_cast<AppListTestItem*>(item);
}
« no previous file with comments | « ui/app_list/shower/app_list_shower_impl_unittest.cc ('k') | ui/app_list/test/app_list_test_view_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698