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

Unified Diff: chrome/browser/chromeos/extensions/file_manager/private_api_file_system.cc

Issue 1194783002: Add fileManagerPrivate.onCopyError event. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove const and rename enum. Created 5 years, 6 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
Index: chrome/browser/chromeos/extensions/file_manager/private_api_file_system.cc
diff --git a/chrome/browser/chromeos/extensions/file_manager/private_api_file_system.cc b/chrome/browser/chromeos/extensions/file_manager/private_api_file_system.cc
index 3df5a307e003d826d19e8d12a03fefa6325c47ec..642aeaf1deacf61d60ea4f5fbdaf6abf52148ee3 100644
--- a/chrome/browser/chromeos/extensions/file_manager/private_api_file_system.cc
+++ b/chrome/browser/chromeos/extensions/file_manager/private_api_file_system.cc
@@ -184,18 +184,19 @@ storage::FileSystemOperationRunner::OperationID StartCopyOnIOThread(
// Note: |operation_id| is owned by the callback for
// FileSystemOperationRunner::Copy(). It is always called in the next message
// loop or later, so at least during this invocation it should alive.
+ //
+ // TODO(yawano): change ERROR_BEHAVIOR_ABORT to ERROR_BEHAVIOR_SKIP after
+ // error messages of individual operations become appear in the Files.app
+ // UI.
storage::FileSystemOperationRunner::OperationID* operation_id =
new storage::FileSystemOperationRunner::OperationID;
*operation_id = file_system_context->operation_runner()->Copy(
- source_url,
- destination_url,
+ source_url, destination_url,
storage::FileSystemOperation::OPTION_PRESERVE_LAST_MODIFIED,
+ storage::FileSystemOperation::ERROR_BEHAVIOR_ABORT,
base::Bind(&OnCopyProgress, profile_id, base::Unretained(operation_id)),
- base::Bind(&OnCopyCompleted,
- profile_id,
- base::Owned(operation_id),
- source_url,
- destination_url));
+ base::Bind(&OnCopyCompleted, profile_id, base::Owned(operation_id),
+ source_url, destination_url));
return *operation_id;
}

Powered by Google App Engine
This is Rietveld 408576698