Chromium Code Reviews| Index: ui/events/gestures/gesture_provider_aura.cc |
| diff --git a/ui/events/gestures/gesture_provider_aura.cc b/ui/events/gestures/gesture_provider_aura.cc |
| index 0db2e04f882d52dd017c8e31a33d5a6638eabea7..43aaf8ad5d4dad580602034435586d4ac2974cd1 100644 |
| --- a/ui/events/gestures/gesture_provider_aura.cc |
| +++ b/ui/events/gestures/gesture_provider_aura.cc |
| @@ -22,6 +22,7 @@ GestureProviderAura::~GestureProviderAura() {} |
| bool GestureProviderAura::OnTouchEvent(const TouchEvent& event) { |
| last_touch_event_flags_ = event.flags(); |
| + last_touch_event_latency_info_ = *event.latency(); |
| bool pointer_id_is_active = false; |
| for (size_t i = 0; i < pointer_state_.GetPointerCount(); ++i) { |
| if (event.touch_id() != pointer_state_.GetPointerId(i)) |
| @@ -80,6 +81,18 @@ void GestureProviderAura::OnGestureEvent( |
| // used when one finger is down, and will eventually |
| // be cleaned up. See crbug.com/366707. |
| 1 << gesture.motion_event_id); |
| + |
| + ui::LatencyInfo* gesture_latency = event.latency(); |
| + gesture_latency->CopyLatencyFrom( |
| + last_touch_event_latency_info_, |
|
Yufeng Shen (Slow to review)
2014/06/02 18:27:04
so is it guaranteed that the this gesture is deriv
tdresser
2014/06/02 18:30:04
Yes, although this would attribute a gesture fired
Yufeng Shen (Slow to review)
2014/06/02 18:43:35
Is it easy to add some latency components to the g
tdresser
2014/06/02 20:04:11
I've gone with the existing Aura behavior, which i
|
| + ui::INPUT_EVENT_LATENCY_ORIGINAL_COMPONENT); |
| + gesture_latency->CopyLatencyFrom( |
| + last_touch_event_latency_info_, |
| + ui::INPUT_EVENT_LATENCY_UI_COMPONENT); |
| + gesture_latency->CopyLatencyFrom( |
| + last_touch_event_latency_info_, |
| + ui::INPUT_EVENT_LATENCY_ACKED_TOUCH_COMPONENT); |
| + |
| client_->OnGestureEvent(&event); |
| } |