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

Side by Side Diff: ui/events/ozone/evdev/event_converter_evdev.cc

Issue 2408063005: Expand event timestamp timebase check to ozone/android (Closed)
Patch Set: Created 4 years, 2 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 unified diff | Download patch
« no previous file with comments | « ui/events/android/motion_event_android.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 <errno.h> 5 #include <errno.h>
6 #include <linux/input.h> 6 #include <linux/input.h>
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include "ui/events/ozone/evdev/event_converter_evdev.h" 9 #include "ui/events/ozone/evdev/event_converter_evdev.h"
10 10
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 } 147 }
148 148
149 void EventConverterEvdev::SetTouchEventLoggingEnabled(bool enabled) { 149 void EventConverterEvdev::SetTouchEventLoggingEnabled(bool enabled) {
150 } 150 }
151 151
152 void EventConverterEvdev::SetPalmSuppressionCallback( 152 void EventConverterEvdev::SetPalmSuppressionCallback(
153 const base::Callback<void(bool)>& callback) {} 153 const base::Callback<void(bool)>& callback) {}
154 154
155 base::TimeTicks EventConverterEvdev::TimeTicksFromInputEvent( 155 base::TimeTicks EventConverterEvdev::TimeTicksFromInputEvent(
156 const input_event& event) { 156 const input_event& event) {
157 return ui::EventTimeStampFromSeconds(event.time.tv_sec) + 157 base::TimeTicks timestamp =
158 ui::EventTimeStampFromSeconds(event.time.tv_sec) +
158 base::TimeDelta::FromMicroseconds(event.time.tv_usec); 159 base::TimeDelta::FromMicroseconds(event.time.tv_usec);
160 ValidateEventTimeClock(&timestamp);
161 return timestamp;
159 } 162 }
160 } // namespace ui 163 } // namespace ui
OLDNEW
« no previous file with comments | « ui/events/android/motion_event_android.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698