Commit e78baea1 authored by Reilly Grant's avatar Reilly Grant Committed by Commit Bot

Convert base::Bind and base::Callback in apps to Once/Repeating

Bug: 1007632
Change-Id: Ic571ca1cb670e8387ff64b3e6f84aee3f6679a4f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1931152
Auto-Submit: Reilly Grant <reillyg@chromium.org>
Commit-Queue: Trent Apted <tapted@chromium.org>
Reviewed-by: default avatarTrent Apted <tapted@chromium.org>
Cr-Commit-Position: refs/heads/master@{#719407}
parent bc7dbccc
......@@ -146,8 +146,8 @@ class PlatformAppPathLauncher
is_directory_collector_.CollectForEntriesPaths(
entry_paths_,
base::Bind(&PlatformAppPathLauncher::OnAreDirectoriesCollected, this,
HasFileSystemWritePermission(app)));
base::BindOnce(&PlatformAppPathLauncher::OnAreDirectoriesCollected,
this, HasFileSystemWritePermission(app)));
}
void LaunchWithHandler(const std::string& handler_id) {
......@@ -189,9 +189,9 @@ class PlatformAppPathLauncher
void OnFilesValid(std::unique_ptr<std::set<base::FilePath>> directory_paths) {
mime_type_collector_.CollectForLocalPaths(
entry_paths_,
base::Bind(
base::BindOnce(
&PlatformAppPathLauncher::OnAreDirectoriesAndMimeTypesCollected,
this, base::Passed(std::move(directory_paths))));
this, std::move(directory_paths)));
}
void OnFilesInvalid(const base::FilePath& /* error_path */) {
......@@ -224,9 +224,9 @@ class PlatformAppPathLauncher
directory_paths.get();
PrepareFilesForWritableApp(
entry_paths_, context_, *directory_paths_ptr,
base::Bind(&PlatformAppPathLauncher::OnFilesValid, this,
base::Passed(std::move(directory_paths))),
base::Bind(&PlatformAppPathLauncher::OnFilesInvalid, this));
base::BindOnce(&PlatformAppPathLauncher::OnFilesValid, this,
std::move(directory_paths)),
base::BindOnce(&PlatformAppPathLauncher::OnFilesInvalid, this));
return;
}
......@@ -295,8 +295,8 @@ class PlatformAppPathLauncher
if (queue->ShouldEnqueueTask(context_, app)) {
queue->AddPendingTask(
context_id,
base::Bind(&PlatformAppPathLauncher::GrantAccessToFilesAndLaunch,
this));
base::BindOnce(&PlatformAppPathLauncher::GrantAccessToFilesAndLaunch,
this));
return;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment