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

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

Issue 8203005: Implement chrome.experimental.downloads.onChanged (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: " Created 8 years, 11 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_stats.h" 5 #include "content/browser/download/download_stats.h"
6 6
7 #include "base/metrics/histogram.h" 7 #include "base/metrics/histogram.h"
8 #include "base/string_util.h" 8 #include "base/string_util.h"
9 #include "content/browser/download/download_resource_handler.h" 9 #include "content/browser/download/download_resource_handler.h"
10 #include "content/browser/download/interrupt_reasons.h" 10 #include "content/browser/download/interrupt_reasons.h"
(...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after
310 } 310 }
311 311
312 void RecordOpensOutstanding(int size) { 312 void RecordOpensOutstanding(int size) {
313 UMA_HISTOGRAM_CUSTOM_COUNTS("Download.OpensOutstanding", 313 UMA_HISTOGRAM_CUSTOM_COUNTS("Download.OpensOutstanding",
314 size, 314 size,
315 0/*min*/, 315 0/*min*/,
316 (1 << 10)/*max*/, 316 (1 << 10)/*max*/,
317 64/*num_buckets*/); 317 64/*num_buckets*/);
318 } 318 }
319 319
320 void RecordOnChanged(int percent) {
321 UMA_HISTOGRAM_PERCENTAGE("Download.OnChanged", percent);
322 }
323
320 } // namespace download_stats 324 } // namespace download_stats
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698