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

Unified Diff: net/base/bandwidth_metrics.h

Issue 864943002: Replaces instances of the deprecated TimeTicks::HighResNow() with TimeTicks::Now(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: More changes based on review comments. Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/test/pipeline_integration_perftest.cc ('k') | skia/ext/benchmarking_canvas.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/base/bandwidth_metrics.h
diff --git a/net/base/bandwidth_metrics.h b/net/base/bandwidth_metrics.h
index e5f2646c7dc71ad5b0a96e1f5d94eaa0ab5fb56a..679d65a673b6b1ad3ad05886efae235e4b563b0d 100644
--- a/net/base/bandwidth_metrics.h
+++ b/net/base/bandwidth_metrics.h
@@ -70,7 +70,7 @@ class BandwidthMetrics {
// If we're the only stream, we've finished some idle time. Record a new
// timestamp to indicate the start of data flow.
if (++num_streams_in_progress_ == 1) {
- last_start_ = base::TimeTicks::HighResNow();
+ last_start_ = base::TimeTicks::Now();
bytes_since_last_start_ = 0;
}
}
@@ -86,7 +86,7 @@ class BandwidthMetrics {
if (bytes_since_last_start_ < kRecordSizeThreshold)
return;
- base::TimeDelta delta = base::TimeTicks::HighResNow() - last_start_;
+ base::TimeDelta delta = base::TimeTicks::Now() - last_start_;
double ms = delta.InMillisecondsF();
if (ms > 0.0) {
double kbps = static_cast<double>(bytes_since_last_start_) * 8 / ms;
« no previous file with comments | « media/test/pipeline_integration_perftest.cc ('k') | skia/ext/benchmarking_canvas.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698