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

Unified Diff: apps/launcher.cc

Issue 1851373002: convert //apps to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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 | « apps/custom_launcher_page_contents.cc ('k') | apps/saved_files_service.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: apps/launcher.cc
diff --git a/apps/launcher.cc b/apps/launcher.cc
index 2ae064873eaf049af69632a2e9d176748ebb181b..02c630279efeff15a2e8a9b58552cc184014d8a2 100644
--- a/apps/launcher.cc
+++ b/apps/launcher.cc
@@ -4,6 +4,7 @@
#include "apps/launcher.h"
+#include <memory>
#include <set>
#include <utility>
@@ -12,7 +13,6 @@
#include "base/files/file_util.h"
#include "base/logging.h"
#include "base/memory/ref_counted.h"
-#include "base/memory/scoped_ptr.h"
#include "base/strings/string_util.h"
#include "base/strings/utf_string_conversions.h"
#include "chrome/browser/extensions/api/file_handlers/app_file_handler_util.h"
@@ -175,7 +175,7 @@ class PlatformAppPathLauncher
base::Bind(&PlatformAppPathLauncher::Launch, this));
}
- void OnFilesValid(scoped_ptr<std::set<base::FilePath>> directory_paths) {
+ void OnFilesValid(std::unique_ptr<std::set<base::FilePath>> directory_paths) {
mime_type_collector_.CollectForLocalPaths(
entry_paths_,
base::Bind(
@@ -201,7 +201,7 @@ class PlatformAppPathLauncher
void OnAreDirectoriesCollected(
bool has_file_system_write_permission,
- scoped_ptr<std::set<base::FilePath>> directory_paths) {
+ std::unique_ptr<std::set<base::FilePath>> directory_paths) {
if (has_file_system_write_permission) {
std::set<base::FilePath>* const directory_paths_ptr =
directory_paths.get();
@@ -217,8 +217,8 @@ class PlatformAppPathLauncher
}
void OnAreDirectoriesAndMimeTypesCollected(
- scoped_ptr<std::set<base::FilePath>> directory_paths,
- scoped_ptr<std::vector<std::string>> mime_types) {
+ std::unique_ptr<std::set<base::FilePath>> directory_paths,
+ std::unique_ptr<std::vector<std::string>> mime_types) {
DCHECK(entry_paths_.size() == mime_types->size());
// If fetching a mime type failed, then use a fallback one.
for (size_t i = 0; i < entry_paths_.size(); ++i) {
« no previous file with comments | « apps/custom_launcher_page_contents.cc ('k') | apps/saved_files_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698