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

Unified Diff: content/browser/android/content_view_core_impl.cc

Issue 1975533002: Change ui::Event::time_stamp from TimeDelta to TimeTicks (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 6 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 | « components/mus/ws/event_matcher_unittest.cc ('k') | content/browser/media/capture/cursor_renderer_aura.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/android/content_view_core_impl.cc
diff --git a/content/browser/android/content_view_core_impl.cc b/content/browser/android/content_view_core_impl.cc
index e6082525515414d1cd375b148221e6775e5223fe..7d636b6f9cd372551f017f41d54572848b612c65 100644
--- a/content/browser/android/content_view_core_impl.cc
+++ b/content/browser/android/content_view_core_impl.cc
@@ -1040,8 +1040,9 @@ jboolean ContentViewCoreImpl::SendMouseWheelEvent(
return false;
// Compute Event.Latency.OS.MOUSE_WHEEL histogram.
- base::TimeDelta current_time = ui::EventTimeForNow();
- base::TimeDelta event_time = base::TimeDelta::FromMilliseconds(time_ms);
+ base::TimeTicks current_time = ui::EventTimeForNow();
+ base::TimeTicks event_time = base::TimeTicks() +
+ base::TimeDelta::FromMilliseconds(time_ms);
base::TimeDelta delta = current_time - event_time;
UMA_HISTOGRAM_CUSTOM_COUNTS("Event.Latency.OS.MOUSE_WHEEL",
delta.InMicroseconds(), 1, 1000000, 50);
« no previous file with comments | « components/mus/ws/event_matcher_unittest.cc ('k') | content/browser/media/capture/cursor_renderer_aura.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698