| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "components/storage_monitor/test_media_transfer_protocol_manager_linux.
h" | 5 #include "components/storage_monitor/test_media_transfer_protocol_manager_linux.
h" |
| 6 | 6 |
| 7 #include "device/media_transfer_protocol/mtp_file_entry.pb.h" | 7 #include "device/media_transfer_protocol/mtp_file_entry.pb.h" |
| 8 | 8 |
| 9 namespace storage_monitor { | 9 namespace storage_monitor { |
| 10 | 10 |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 } | 36 } |
| 37 | 37 |
| 38 void TestMediaTransferProtocolManagerLinux::CloseStorage( | 38 void TestMediaTransferProtocolManagerLinux::CloseStorage( |
| 39 const std::string& storage_handle, | 39 const std::string& storage_handle, |
| 40 const CloseStorageCallback& callback) { | 40 const CloseStorageCallback& callback) { |
| 41 callback.Run(true); | 41 callback.Run(true); |
| 42 } | 42 } |
| 43 | 43 |
| 44 void TestMediaTransferProtocolManagerLinux::ReadDirectory( | 44 void TestMediaTransferProtocolManagerLinux::ReadDirectory( |
| 45 const std::string& storage_handle, | 45 const std::string& storage_handle, |
| 46 uint32 file_id, | 46 const uint32 file_id, |
| 47 const size_t max_size, |
| 47 const ReadDirectoryCallback& callback) { | 48 const ReadDirectoryCallback& callback) { |
| 48 callback.Run(std::vector<MtpFileEntry>(), | 49 callback.Run(std::vector<MtpFileEntry>(), |
| 49 false /* no more entries*/, | 50 false /* no more entries*/, |
| 50 true /* error */); | 51 true /* error */); |
| 51 } | 52 } |
| 52 | 53 |
| 53 void TestMediaTransferProtocolManagerLinux::ReadFileChunk( | 54 void TestMediaTransferProtocolManagerLinux::ReadFileChunk( |
| 54 const std::string& storage_handle, | 55 const std::string& storage_handle, |
| 55 uint32 file_id, | 56 uint32 file_id, |
| 56 uint32 offset, | 57 uint32 offset, |
| (...skipping 11 matching lines...) Expand all Loading... |
| 68 | 69 |
| 69 void TestMediaTransferProtocolManagerLinux::CopyFileFromLocal( | 70 void TestMediaTransferProtocolManagerLinux::CopyFileFromLocal( |
| 70 const std::string& storage_handle, | 71 const std::string& storage_handle, |
| 71 const int source_file_descriptor, | 72 const int source_file_descriptor, |
| 72 const uint32 parent_id, | 73 const uint32 parent_id, |
| 73 const std::string& file_name, | 74 const std::string& file_name, |
| 74 const CopyFileFromLocalCallback& callback) { | 75 const CopyFileFromLocalCallback& callback) { |
| 75 callback.Run(true /* error */); | 76 callback.Run(true /* error */); |
| 76 } | 77 } |
| 77 | 78 |
| 79 void TestMediaTransferProtocolManagerLinux::DeleteObject( |
| 80 const std::string& storage_handle, |
| 81 const uint32 object_id, |
| 82 const DeleteObjectCallback& callback) { |
| 83 callback.Run(true /* error */); |
| 84 } |
| 85 |
| 78 } // namespace storage_monitor | 86 } // namespace storage_monitor |
| OLD | NEW |