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

Unified Diff: content/browser/download/download_item_impl.cc

Issue 2750713003: Add UMA for estimating disk bandwidth and the time saved with parallel download (Closed)
Patch Set: address comments Created 3 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/download/download_file_impl.cc ('k') | content/browser/download/download_stats.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 f118a476be598052f23acd1ffe392e303b084e39..2e998f079d0606ba07f3875eac852da15983fd14 100644
--- a/content/browser/download/download_item_impl.cc
+++ b/content/browser/download/download_item_impl.cc
@@ -378,6 +378,13 @@ void DownloadItemImpl::Pause() {
case TARGET_PENDING_INTERNAL:
job_->Pause();
UpdateObservers();
+ if (download_file_) {
+ BrowserThread::PostTask(
+ BrowserThread::FILE, FROM_HERE,
+ base::Bind(&DownloadFile::WasPaused,
+ // Safe because we control download file lifetime.
+ base::Unretained(download_file_.get())));
+ }
return;
case MAX_DOWNLOAD_INTERNAL_STATE:
« no previous file with comments | « content/browser/download/download_file_impl.cc ('k') | content/browser/download/download_stats.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698