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

Side by Side Diff: ui/events/event.cc

Issue 538143002: Fix test for master device. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Identify virtual core keyboard. Created 6 years, 3 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/event.h" 5 #include "ui/events/event.h"
6 6
7 #if defined(USE_X11) 7 #if defined(USE_X11)
8 #include <X11/extensions/XInput2.h> 8 #include <X11/extensions/XInput2.h>
9 #include <X11/Xlib.h> 9 #include <X11/Xlib.h>
10 #endif 10 #endif
(...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after
223 1, 223 1,
224 1000000, 224 1000000,
225 100, 225 100,
226 base::HistogramBase::kUmaTargetedHistogramFlag); 226 base::HistogramBase::kUmaTargetedHistogramFlag);
227 counter_for_type->Add(delta.InMicroseconds()); 227 counter_for_type->Add(delta.InMicroseconds());
228 228
229 #if defined(USE_X11) 229 #if defined(USE_X11)
230 if (native_event->type == GenericEvent) { 230 if (native_event->type == GenericEvent) {
231 XIDeviceEvent* xiev = 231 XIDeviceEvent* xiev =
232 static_cast<XIDeviceEvent*>(native_event->xcookie.data); 232 static_cast<XIDeviceEvent*>(native_event->xcookie.data);
233 source_device_id_ = xiev->deviceid; 233 source_device_id_ = xiev->sourceid;
234 } 234 }
235 #endif 235 #endif
236 } 236 }
237 237
238 Event::Event(const Event& copy) 238 Event::Event(const Event& copy)
239 : type_(copy.type_), 239 : type_(copy.type_),
240 time_stamp_(copy.time_stamp_), 240 time_stamp_(copy.time_stamp_),
241 latency_(copy.latency_), 241 latency_(copy.latency_),
242 flags_(copy.flags_), 242 flags_(copy.flags_),
243 native_event_(CopyNativeEvent(copy.native_event_)), 243 native_event_(CopyNativeEvent(copy.native_event_)),
(...skipping 614 matching lines...) Expand 10 before | Expand all | Expand 10 after
858 gfx::PointF(x, y), 858 gfx::PointF(x, y),
859 time_stamp, 859 time_stamp,
860 flags | EF_FROM_TOUCH), 860 flags | EF_FROM_TOUCH),
861 details_(details) { 861 details_(details) {
862 } 862 }
863 863
864 GestureEvent::~GestureEvent() { 864 GestureEvent::~GestureEvent() {
865 } 865 }
866 866
867 } // namespace ui 867 } // namespace ui
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/events/event_rewriter_unittest.cc ('k') | ui/events/test/events_test_utils_x11.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698