feat: macOS removal fallback when moveItemToTrash fails (#19700)

* feat: macOS removal fallback when moveItemToTrash fails

* platform_util shouldn't know about mate::Arguments

* pull full_path from args as well
This commit is contained in:
Shelley Vohr 2019-08-13 12:31:53 -07:00 committed by GitHub
parent b5798326e8
commit e1824c00a9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 43 additions and 13 deletions

View file

@ -82,7 +82,7 @@ void OpenExternal(const GURL& url,
std::move(callback).Run(XDGOpen(url.spec(), false) ? "" : "Failed to open");
}
bool MoveItemToTrash(const base::FilePath& full_path) {
bool MoveItemToTrash(const base::FilePath& full_path, bool delete_on_fail) {
std::unique_ptr<base::Environment> env(base::Environment::Create());
// find the trash method