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

Unified Diff: ui/events/ozone/evdev/input_injector_evdev.cc

Issue 889673004: ozone: evdev: Use kernel timestamps for mouse events (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase on MouseEvent timestamp changes & fix stime feedback Created 5 years, 10 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: ui/events/ozone/evdev/input_injector_evdev.cc
diff --git a/ui/events/ozone/evdev/input_injector_evdev.cc b/ui/events/ozone/evdev/input_injector_evdev.cc
index 843a9900aacf801589ee8e4cd22fa1070c2906e1..fdb8e1f8016ead53b1425159b447162eaa7c4bd1 100644
--- a/ui/events/ozone/evdev/input_injector_evdev.cc
+++ b/ui/events/ozone/evdev/input_injector_evdev.cc
@@ -45,15 +45,15 @@ void InputInjectorEvdev::InjectMouseButton(EventFlags button, bool down) {
return;
}
- dispatcher_->DispatchMouseButtonEvent(
- MouseButtonEventParams(kDeviceIdForInjection, cursor_->GetLocation(),
- code, down, false /* allow_remap */));
+ dispatcher_->DispatchMouseButtonEvent(MouseButtonEventParams(
+ kDeviceIdForInjection, cursor_->GetLocation(), code, down,
+ false /* allow_remap */, EventTimeForNow()));
}
void InputInjectorEvdev::InjectMouseWheel(int delta_x, int delta_y) {
- dispatcher_->DispatchMouseWheelEvent(
- MouseWheelEventParams(kDeviceIdForInjection, cursor_->GetLocation(),
- gfx::Vector2d(delta_x, delta_y)));
+ dispatcher_->DispatchMouseWheelEvent(MouseWheelEventParams(
+ kDeviceIdForInjection, cursor_->GetLocation(),
+ gfx::Vector2d(delta_x, delta_y), EventTimeForNow()));
}
void InputInjectorEvdev::MoveCursorTo(const gfx::PointF& location) {
@@ -62,8 +62,8 @@ void InputInjectorEvdev::MoveCursorTo(const gfx::PointF& location) {
cursor_->MoveCursorTo(location);
- dispatcher_->DispatchMouseMoveEvent(
- MouseMoveEventParams(kDeviceIdForInjection, cursor_->GetLocation()));
+ dispatcher_->DispatchMouseMoveEvent(MouseMoveEventParams(
+ kDeviceIdForInjection, cursor_->GetLocation(), EventTimeForNow()));
}
void InputInjectorEvdev::InjectKeyPress(DomCode physical_key, bool down) {

Powered by Google App Engine
This is Rietveld 408576698