| Index: content/browser/download/download_item_impl.cc
|
| diff --git a/content/browser/download/download_item_impl.cc b/content/browser/download/download_item_impl.cc
|
| index 1132560218034b46a8b1e4f9f82f8c51bc726877..cda8b841a34ecab3ef48c12d10752bd7f15034b5 100644
|
| --- a/content/browser/download/download_item_impl.cc
|
| +++ b/content/browser/download/download_item_impl.cc
|
| @@ -1063,12 +1063,6 @@ void DownloadItemImpl::UpdateValidatorsOnResumption(
|
| // notified when the download transitions to the IN_PROGRESS state.
|
| }
|
|
|
| -void DownloadItemImpl::CancelRequestWithOffset(int64_t offset) {
|
| - DCHECK_CURRENTLY_ON(BrowserThread::UI);
|
| - if (job_)
|
| - job_->CancelRequestWithOffset(offset);
|
| -}
|
| -
|
| void DownloadItemImpl::NotifyRemoved() {
|
| for (auto& observer : observers_)
|
| observer.OnDownloadRemoved(this);
|
| @@ -1324,20 +1318,10 @@ void DownloadItemImpl::Start(
|
|
|
| TransitionTo(TARGET_PENDING_INTERNAL);
|
|
|
| - job_->Start();
|
| -}
|
| -
|
| -void DownloadItemImpl::StartDownload() {
|
| - BrowserThread::PostTask(
|
| - BrowserThread::FILE, FROM_HERE,
|
| - base::Bind(&DownloadFile::Initialize,
|
| - // Safe because we control download file lifetime.
|
| - base::Unretained(download_file_.get()),
|
| - base::Bind(&DownloadItemImpl::OnDownloadFileInitialized,
|
| - weak_ptr_factory_.GetWeakPtr()),
|
| - base::Bind(&DownloadItemImpl::CancelRequestWithOffset,
|
| - weak_ptr_factory_.GetWeakPtr()),
|
| - received_slices_, job_ && job_->IsParallelizable()));
|
| + job_->Start(download_file_.get(),
|
| + base::Bind(&DownloadItemImpl::OnDownloadFileInitialized,
|
| + weak_ptr_factory_.GetWeakPtr()),
|
| + GetReceivedSlices());
|
| }
|
|
|
| void DownloadItemImpl::OnDownloadFileInitialized(
|
|
|