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

Unified Diff: trunk/src/content/browser/renderer_host/input/touch_emulator.cc

Issue 287153007: Revert 271026 "[DevTools] Interactive test for DevTools touch em..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 7 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: trunk/src/content/browser/renderer_host/input/touch_emulator.cc
===================================================================
--- trunk/src/content/browser/renderer_host/input/touch_emulator.cc (revision 271031)
+++ trunk/src/content/browser/renderer_host/input/touch_emulator.cc (working copy)
@@ -131,8 +131,7 @@
if (mouse_event.button != WebMouseEvent::ButtonLeft)
return true;
- if (mouse_event.type == WebInputEvent::MouseMove &&
- mouse_event.timeStampSeconds) {
+ if (mouse_event.type == WebInputEvent::MouseMove) {
if (last_mouse_event_was_move_ &&
mouse_event.timeStampSeconds < last_mouse_move_timestamp_ +
kMouseMoveDropIntervalSeconds)
@@ -317,7 +316,7 @@
client_->ForwardGestureEvent(pinch_event_);
}
-void TouchEmulator::FillPinchEvent(const WebGestureEvent& event) {
+void TouchEmulator::FillPinchEvent(const WebInputEvent& event) {
pinch_event_.timeStampSeconds = event.timeStampSeconds;
pinch_event_.modifiers = event.modifiers;
pinch_event_.sourceDevice = blink::WebGestureEvent::Touchscreen;
@@ -363,12 +362,6 @@
WebTouchEventTraits::ResetTypeAndTouchStates(
eventType, mouse_event.timeStampSeconds, &touch_event_);
- if (!touch_event_.timeStampSeconds) {
- // Gesture detector does not tolerate null timestamps generated in tests.
- touch_event_.timeStampSeconds =
- (base::TimeTicks::Now() - base::TimeTicks()).InSecondsF();
- }
-
WebTouchPoint& point = touch_event_.touches[0];
point.id = 0;
point.radiusX = point.radiusY = 1.f;

Powered by Google App Engine
This is Rietveld 408576698