OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "ui/events/gesture_detection/motion_event_buffer.h" | 5 #include "ui/events/gesture_detection/motion_event_buffer.h" |
6 | 6 |
7 #include "base/debug/trace_event.h" | 7 #include "base/trace_event/trace_event.h" |
8 #include "ui/events/gesture_detection/motion_event.h" | 8 #include "ui/events/gesture_detection/motion_event.h" |
9 #include "ui/events/gesture_detection/motion_event_generic.h" | 9 #include "ui/events/gesture_detection/motion_event_generic.h" |
10 | 10 |
11 namespace ui { | 11 namespace ui { |
12 namespace { | 12 namespace { |
13 | 13 |
14 // Latency added during resampling. A few milliseconds doesn't hurt much but | 14 // Latency added during resampling. A few milliseconds doesn't hurt much but |
15 // reduces the impact of mispredicted touch positions. | 15 // reduces the impact of mispredicted touch positions. |
16 const int kResampleLatencyMs = 5; | 16 const int kResampleLatencyMs = 5; |
17 | 17 |
(...skipping 428 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
446 events.weak_clear(); | 446 events.weak_clear(); |
447 client_->ForwardMotionEvent(*event); | 447 client_->ForwardMotionEvent(*event); |
448 return; | 448 return; |
449 } | 449 } |
450 | 450 |
451 CompoundMotionEvent compound_event(events.Pass()); | 451 CompoundMotionEvent compound_event(events.Pass()); |
452 client_->ForwardMotionEvent(compound_event); | 452 client_->ForwardMotionEvent(compound_event); |
453 } | 453 } |
454 | 454 |
455 } // namespace ui | 455 } // namespace ui |
OLD | NEW |