| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/sync_file_system/local/canned_syncable_file_system.h" | 5 #include "chrome/browser/sync_file_system/local/canned_syncable_file_system.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <iterator> | 8 #include <iterator> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 547 const StatusCallback& callback) { | 547 const StatusCallback& callback) { |
| 548 EXPECT_TRUE(is_filesystem_opened_); | 548 EXPECT_TRUE(is_filesystem_opened_); |
| 549 operation_runner()->CreateFile(url, false /* exclusive */, callback); | 549 operation_runner()->CreateFile(url, false /* exclusive */, callback); |
| 550 } | 550 } |
| 551 | 551 |
| 552 void CannedSyncableFileSystem::DoCopy( | 552 void CannedSyncableFileSystem::DoCopy( |
| 553 const FileSystemURL& src_url, | 553 const FileSystemURL& src_url, |
| 554 const FileSystemURL& dest_url, | 554 const FileSystemURL& dest_url, |
| 555 const StatusCallback& callback) { | 555 const StatusCallback& callback) { |
| 556 EXPECT_TRUE(is_filesystem_opened_); | 556 EXPECT_TRUE(is_filesystem_opened_); |
| 557 operation_runner()->Copy(src_url, dest_url, callback); | 557 operation_runner()->Copy( |
| 558 src_url, dest_url, |
| 559 fileapi::FileSystemOperationRunner::CopyProgressCallback(), callback); |
| 558 } | 560 } |
| 559 | 561 |
| 560 void CannedSyncableFileSystem::DoMove( | 562 void CannedSyncableFileSystem::DoMove( |
| 561 const FileSystemURL& src_url, | 563 const FileSystemURL& src_url, |
| 562 const FileSystemURL& dest_url, | 564 const FileSystemURL& dest_url, |
| 563 const StatusCallback& callback) { | 565 const StatusCallback& callback) { |
| 564 EXPECT_TRUE(is_filesystem_opened_); | 566 EXPECT_TRUE(is_filesystem_opened_); |
| 565 operation_runner()->Move(src_url, dest_url, callback); | 567 operation_runner()->Move(src_url, dest_url, callback); |
| 566 } | 568 } |
| 567 | 569 |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 678 sync_status_ = status; | 680 sync_status_ = status; |
| 679 base::MessageLoop::current()->Quit(); | 681 base::MessageLoop::current()->Quit(); |
| 680 } | 682 } |
| 681 | 683 |
| 682 void CannedSyncableFileSystem::InitializeSyncStatusObserver() { | 684 void CannedSyncableFileSystem::InitializeSyncStatusObserver() { |
| 683 ASSERT_TRUE(io_task_runner_->RunsTasksOnCurrentThread()); | 685 ASSERT_TRUE(io_task_runner_->RunsTasksOnCurrentThread()); |
| 684 backend()->sync_context()->sync_status()->AddObserver(this); | 686 backend()->sync_context()->sync_status()->AddObserver(this); |
| 685 } | 687 } |
| 686 | 688 |
| 687 } // namespace sync_file_system | 689 } // namespace sync_file_system |
| OLD | NEW |