| Index: chrome/browser/media_galleries/linux/mtp_device_task_helper.h
|
| diff --git a/chrome/browser/media_galleries/linux/mtp_device_task_helper.h b/chrome/browser/media_galleries/linux/mtp_device_task_helper.h
|
| index 31ac534c52454a0e6155e54f789abddd7c0ed27e..1825e8b85db9a907ff8d6da19ee612edc2a3c5f8 100644
|
| --- a/chrome/browser/media_galleries/linux/mtp_device_task_helper.h
|
| +++ b/chrome/browser/media_galleries/linux/mtp_device_task_helper.h
|
| @@ -36,6 +36,8 @@ class MTPDeviceTaskHelper {
|
| typedef base::Callback<void(const storage::AsyncFileUtil::EntryList& entries,
|
| bool has_more)> ReadDirectorySuccessCallback;
|
|
|
| + typedef base::Closure CopyFileFromLocalSuccessCallback;
|
| +
|
| typedef MTPDeviceAsyncDelegate::ErrorCallback ErrorCallback;
|
|
|
| MTPDeviceTaskHelper();
|
| @@ -95,6 +97,15 @@ class MTPDeviceTaskHelper {
|
| // called on the IO thread to notify the caller about success or failure.
|
| void ReadBytes(const MTPDeviceAsyncDelegate::ReadBytesRequest& request);
|
|
|
| + // Forwards CopyFileFromLocal request to the MediaTransferProtocolManager.
|
| + void CopyFileFromLocal(
|
| + const std::string& storage_name,
|
| + const uint32 source_file_descriptor,
|
| + const uint32 parent_id,
|
| + const std::string& file_name,
|
| + const CopyFileFromLocalSuccessCallback& success_callback,
|
| + const ErrorCallback& error_callback);
|
| +
|
| // Dispatches the CloseStorage request to the MediaTransferProtocolManager.
|
| void CloseStorage() const;
|
|
|
| @@ -159,6 +170,12 @@ class MTPDeviceTaskHelper {
|
| const std::string& data,
|
| bool error) const;
|
|
|
| + // Called when CopyFileFromLocal completed either succeeded or failed.
|
| + void OnCopyFileFromLocal(
|
| + const CopyFileFromLocalSuccessCallback& success_callback,
|
| + const ErrorCallback& error_callback,
|
| + const bool error) const;
|
| +
|
| // Called when the device is uninitialized.
|
| //
|
| // Runs |error_callback| on the IO thread to notify the caller about the
|
|
|