OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/drive_scheduler.h" | 5 #include "chrome/browser/chromeos/drive/drive_scheduler.h" |
6 | 6 |
7 #include <math.h> | 7 #include <math.h> |
8 | 8 |
9 #include "base/message_loop.h" | 9 #include "base/message_loop.h" |
10 #include "base/prefs/pref_service.h" | 10 #include "base/prefs/pref_service.h" |
(...skipping 567 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
578 break; | 578 break; |
579 | 579 |
580 case TYPE_DOWNLOAD_FILE: { | 580 case TYPE_DOWNLOAD_FILE: { |
581 drive_service_->DownloadFile( | 581 drive_service_->DownloadFile( |
582 entry->virtual_path, | 582 entry->virtual_path, |
583 entry->local_cache_path, | 583 entry->local_cache_path, |
584 entry->download_url, | 584 entry->download_url, |
585 base::Bind(&DriveScheduler::OnDownloadActionJobDone, | 585 base::Bind(&DriveScheduler::OnDownloadActionJobDone, |
586 weak_ptr_factory_.GetWeakPtr(), | 586 weak_ptr_factory_.GetWeakPtr(), |
587 base::Passed(&queue_entry)), | 587 base::Passed(&queue_entry)), |
588 entry->get_content_callback); | 588 entry->get_content_callback, |
| 589 google_apis::ProgressCallback()); |
589 } | 590 } |
590 break; | 591 break; |
591 | 592 |
592 case TYPE_UPLOAD_NEW_FILE: { | 593 case TYPE_UPLOAD_NEW_FILE: { |
593 uploader_->UploadNewFile( | 594 uploader_->UploadNewFile( |
594 entry->resource_id, | 595 entry->resource_id, |
595 entry->drive_file_path, | 596 entry->drive_file_path, |
596 entry->local_file_path, | 597 entry->local_file_path, |
597 entry->title, | 598 entry->title, |
598 entry->content_type, | 599 entry->content_type, |
(...skipping 302 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
901 case TYPE_DOWNLOAD_FILE: | 902 case TYPE_DOWNLOAD_FILE: |
902 case TYPE_UPLOAD_NEW_FILE: | 903 case TYPE_UPLOAD_NEW_FILE: |
903 case TYPE_UPLOAD_EXISTING_FILE: | 904 case TYPE_UPLOAD_EXISTING_FILE: |
904 return FILE_QUEUE; | 905 return FILE_QUEUE; |
905 } | 906 } |
906 NOTREACHED(); | 907 NOTREACHED(); |
907 return FILE_QUEUE; | 908 return FILE_QUEUE; |
908 } | 909 } |
909 | 910 |
910 } // namespace drive | 911 } // namespace drive |
OLD | NEW |