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 "chrome/browser/chromeos/file_system_provider/fake_provided_file_system
.h" | 5 #include "chrome/browser/chromeos/file_system_provider/fake_provided_file_system
.h" |
6 | 6 |
7 #include "base/files/file.h" | 7 #include "base/files/file.h" |
8 #include "base/message_loop/message_loop_proxy.h" | 8 #include "base/message_loop/message_loop_proxy.h" |
9 #include "net/base/io_buffer.h" | 9 #include "net/base/io_buffer.h" |
10 | 10 |
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
206 } | 206 } |
207 | 207 |
208 return base::Bind(&FakeProvidedFileSystem::AbortMany, | 208 return base::Bind(&FakeProvidedFileSystem::AbortMany, |
209 weak_ptr_factory_.GetWeakPtr(), | 209 weak_ptr_factory_.GetWeakPtr(), |
210 task_ids); | 210 task_ids); |
211 } | 211 } |
212 | 212 |
213 ProvidedFileSystemInterface::AbortCallback | 213 ProvidedFileSystemInterface::AbortCallback |
214 FakeProvidedFileSystem::CreateDirectory( | 214 FakeProvidedFileSystem::CreateDirectory( |
215 const base::FilePath& directory_path, | 215 const base::FilePath& directory_path, |
216 bool exclusive, | |
217 bool recursive, | 216 bool recursive, |
218 const storage::AsyncFileUtil::StatusCallback& callback) { | 217 const storage::AsyncFileUtil::StatusCallback& callback) { |
219 // TODO(mtomasz): Implement it once needed. | 218 // TODO(mtomasz): Implement it once needed. |
220 return PostAbortableTask(base::Bind(callback, base::File::FILE_OK)); | 219 return PostAbortableTask(base::Bind(callback, base::File::FILE_OK)); |
221 } | 220 } |
222 | 221 |
223 ProvidedFileSystemInterface::AbortCallback FakeProvidedFileSystem::DeleteEntry( | 222 ProvidedFileSystemInterface::AbortCallback FakeProvidedFileSystem::DeleteEntry( |
224 const base::FilePath& entry_path, | 223 const base::FilePath& entry_path, |
225 bool recursive, | 224 bool recursive, |
226 const storage::AsyncFileUtil::StatusCallback& callback) { | 225 const storage::AsyncFileUtil::StatusCallback& callback) { |
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
340 const std::vector<int>& task_ids, | 339 const std::vector<int>& task_ids, |
341 const storage::AsyncFileUtil::StatusCallback& callback) { | 340 const storage::AsyncFileUtil::StatusCallback& callback) { |
342 for (size_t i = 0; i < task_ids.size(); ++i) { | 341 for (size_t i = 0; i < task_ids.size(); ++i) { |
343 tracker_.TryCancel(task_ids[i]); | 342 tracker_.TryCancel(task_ids[i]); |
344 } | 343 } |
345 callback.Run(base::File::FILE_OK); | 344 callback.Run(base::File::FILE_OK); |
346 } | 345 } |
347 | 346 |
348 } // namespace file_system_provider | 347 } // namespace file_system_provider |
349 } // namespace chromeos | 348 } // namespace chromeos |
OLD | NEW |