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/chromeos/drive/file_system/download_operation.h" | 5 #include "chrome/browser/chromeos/drive/file_system/download_operation.h" |
6 | 6 |
7 #include "base/callback_helpers.h" | 7 #include "base/callback_helpers.h" |
8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
9 #include "base/files/file_util.h" | 9 #include "base/files/file_util.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
11 #include "base/task_runner_util.h" | 11 #include "base/task_runner_util.h" |
12 #include "chrome/browser/chromeos/drive/drive.pb.h" | 12 #include "chrome/browser/chromeos/drive/drive.pb.h" |
13 #include "chrome/browser/chromeos/drive/file_cache.h" | 13 #include "chrome/browser/chromeos/drive/file_cache.h" |
14 #include "chrome/browser/chromeos/drive/file_change.h" | 14 #include "chrome/browser/chromeos/drive/file_change.h" |
15 #include "chrome/browser/chromeos/drive/file_errors.h" | 15 #include "chrome/browser/chromeos/drive/file_errors.h" |
16 #include "chrome/browser/chromeos/drive/file_system/operation_delegate.h" | 16 #include "chrome/browser/chromeos/drive/file_system/operation_delegate.h" |
17 #include "chrome/browser/chromeos/drive/file_system_util.h" | 17 #include "chrome/browser/chromeos/drive/file_system_core_util.h" |
18 #include "chrome/browser/chromeos/drive/job_scheduler.h" | 18 #include "chrome/browser/chromeos/drive/job_scheduler.h" |
19 #include "chrome/browser/chromeos/drive/resource_metadata.h" | 19 #include "chrome/browser/chromeos/drive/resource_metadata.h" |
20 #include "google_apis/drive/drive_api_error_codes.h" | 20 #include "google_apis/drive/drive_api_error_codes.h" |
21 | 21 |
22 namespace drive { | 22 namespace drive { |
23 namespace file_system { | 23 namespace file_system { |
24 namespace { | 24 namespace { |
25 | 25 |
26 // Generates an unused file path with |extension| to |out_path|, as a descendant | 26 // Generates an unused file path with |extension| to |out_path|, as a descendant |
27 // of |dir|, with its parent directory created. | 27 // of |dir|, with its parent directory created. |
(...skipping 503 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
531 delegate_->OnFileChangedByOperation(changed_files); | 531 delegate_->OnFileChangedByOperation(changed_files); |
532 params->OnDownloadCompleted(*cache_file_path, entry_after_update.Pass()); | 532 params->OnDownloadCompleted(*cache_file_path, entry_after_update.Pass()); |
533 } | 533 } |
534 | 534 |
535 void DownloadOperation::CancelJob(JobID job_id) { | 535 void DownloadOperation::CancelJob(JobID job_id) { |
536 scheduler_->CancelJob(job_id); | 536 scheduler_->CancelJob(job_id); |
537 } | 537 } |
538 | 538 |
539 } // namespace file_system | 539 } // namespace file_system |
540 } // namespace drive | 540 } // namespace drive |
OLD | NEW |