0

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: Trent Apted <tapted@chromium.org>
Cr-Commit-Position: refs/heads/master@{#719407}
This commit is contained in:
Reilly Grant
2019-11-26 23:33:11 +00:00
committed by Commit Bot
parent bc7dbccc3d
commit e78baea1dc

@ -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;
}