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

Unified Diff: content/browser/renderer_host/input/synthetic_gesture.cc

Issue 119323007: Add timestamps to synthesized events. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove target variables in pinch; fix computation of total duration. Created 6 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
Index: content/browser/renderer_host/input/synthetic_gesture.cc
diff --git a/content/browser/renderer_host/input/synthetic_gesture.cc b/content/browser/renderer_host/input/synthetic_gesture.cc
index 8b2b3bedbe63ca9166056987e68b7a47e6e70646..bc887e1dfe2e7ad5aea9b89e2a41ead4cf8c9ca1 100644
--- a/content/browser/renderer_host/input/synthetic_gesture.cc
+++ b/content/browser/renderer_host/input/synthetic_gesture.cc
@@ -43,4 +43,10 @@ scoped_ptr<SyntheticGesture> SyntheticGesture::Create(
return scoped_ptr<SyntheticGesture>();
}
+// static
+double SyntheticGesture::ConvertTimestampToSeconds(
+ const base::TimeTicks& timestamp) {
+ return (timestamp - base::TimeTicks()).InSecondsF();
+}
+
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698