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

Unified Diff: chrome/browser/download/download_throttling_resource_handler.cc

Issue 9316116: Isolate initiation counts for downloads to their own histograms and improve (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Shift recording of UMA to before initiation in all cases. Created 8 years, 10 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
Index: chrome/browser/download/download_throttling_resource_handler.cc
diff --git a/chrome/browser/download/download_throttling_resource_handler.cc b/chrome/browser/download/download_throttling_resource_handler.cc
index 85bc6e19cbaf39fb247f93d8ee8c385c4db1b183..b61f1a5c93cea7cbdebb8cf7bc8a9235c5b9cc88 100644
--- a/chrome/browser/download/download_throttling_resource_handler.cc
+++ b/chrome/browser/download/download_throttling_resource_handler.cc
@@ -134,16 +134,16 @@ void DownloadThrottlingResourceHandler::OnRequestClosed() {
}
void DownloadThrottlingResourceHandler::ContinueDownload(bool allow) {
- download_util::RecordDownloadCount(
- download_util::INITIATED_BY_NAVIGATION_COUNT);
if (request_closed_)
return;
request_allowed_ = allow;
if (allow) {
// And let the request continue.
+ download_util::RecordDownloadSource(download_util::INITIATED_BY_NAVIGATION);
host_->PauseRequest(render_process_host_id_, request_id_, false);
} else {
+ download_util::RecordDownloadSource(download_util::BLOCKED_BY_THROTTLING);
cbentzel 2012/02/07 18:29:32 I don't like having this as a separate source, as
Randy Smith (Not in Mondays) 2012/02/07 19:28:14 Moved into a "Counts" histogram at the chrome laye
host_->CancelRequest(render_process_host_id_, request_id_, false);
}
}

Powered by Google App Engine
This is Rietveld 408576698