Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(143)

Side by Side Diff: content/browser/download/download_manager_impl.cc

Issue 2854973003: Fix the Unthrottled download count for parallel download (Closed)
Patch Set: Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | content/browser/download/download_request_core.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "content/browser/download/download_manager_impl.h" 5 #include "content/browser/download/download_manager_impl.h"
6 6
7 #include <iterator> 7 #include <iterator>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 BrowserThread::PostTask( 101 BrowserThread::PostTask(
102 BrowserThread::UI, FROM_HERE, 102 BrowserThread::UI, FROM_HERE,
103 base::Bind(&DownloadManager::StartDownload, download_manager, 103 base::Bind(&DownloadManager::StartDownload, download_manager,
104 base::Passed(&failed_created_info), 104 base::Passed(&failed_created_info),
105 base::Passed(&empty_byte_stream), params->callback())); 105 base::Passed(&empty_byte_stream), params->callback()));
106 return nullptr; 106 return nullptr;
107 } 107 }
108 108
109 return std::unique_ptr<UrlDownloader, BrowserThread::DeleteOnIOThread>( 109 return std::unique_ptr<UrlDownloader, BrowserThread::DeleteOnIOThread>(
110 UrlDownloader::BeginDownload(download_manager, std::move(url_request), 110 UrlDownloader::BeginDownload(download_manager, std::move(url_request),
111 params->referrer()) 111 params->referrer(), false)
112 .release()); 112 .release());
113 } 113 }
114 114
115 class DownloadItemFactoryImpl : public DownloadItemFactory { 115 class DownloadItemFactoryImpl : public DownloadItemFactory {
116 public: 116 public:
117 DownloadItemFactoryImpl() {} 117 DownloadItemFactoryImpl() {}
118 ~DownloadItemFactoryImpl() override {} 118 ~DownloadItemFactoryImpl() override {}
119 119
120 DownloadItemImpl* CreatePersistedItem( 120 DownloadItemImpl* CreatePersistedItem(
121 DownloadItemImplDelegate* delegate, 121 DownloadItemImplDelegate* delegate,
(...skipping 625 matching lines...) Expand 10 before | Expand all | Expand 10 after
747 if (delegate_) 747 if (delegate_)
748 delegate_->OpenDownload(download); 748 delegate_->OpenDownload(download);
749 } 749 }
750 750
751 void DownloadManagerImpl::ShowDownloadInShell(DownloadItemImpl* download) { 751 void DownloadManagerImpl::ShowDownloadInShell(DownloadItemImpl* download) {
752 if (delegate_) 752 if (delegate_)
753 delegate_->ShowDownloadInShell(download); 753 delegate_->ShowDownloadInShell(download);
754 } 754 }
755 755
756 } // namespace content 756 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/browser/download/download_request_core.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698