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

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

Issue 790153005: ozone: evdev: Add property to identify internal or external devices (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years 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 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 <linux/input.h> 5 #include <linux/input.h>
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/memory/scoped_vector.h" 9 #include "base/memory/scoped_vector.h"
10 #include "base/message_loop/message_loop.h" 10 #include "base/message_loop/message_loop.h"
(...skipping 13 matching lines...) Expand all
24 public: 24 public:
25 MockEventConverterEvdevImpl(int fd, 25 MockEventConverterEvdevImpl(int fd,
26 EventModifiersEvdev* modifiers, 26 EventModifiersEvdev* modifiers,
27 MouseButtonMapEvdev* button_map, 27 MouseButtonMapEvdev* button_map,
28 CursorDelegateEvdev* cursor, 28 CursorDelegateEvdev* cursor,
29 KeyboardEvdev* keyboard, 29 KeyboardEvdev* keyboard,
30 const EventDispatchCallback& callback) 30 const EventDispatchCallback& callback)
31 : EventConverterEvdevImpl(fd, 31 : EventConverterEvdevImpl(fd,
32 base::FilePath(kTestDevicePath), 32 base::FilePath(kTestDevicePath),
33 1, 33 1,
34 INPUT_DEVICE_UNKNOWN,
34 modifiers, 35 modifiers,
35 button_map, 36 button_map,
36 cursor, 37 cursor,
37 keyboard, 38 keyboard,
38 callback) { 39 callback) {
39 Start(); 40 Start();
40 } 41 }
41 ~MockEventConverterEvdevImpl() override {} 42 ~MockEventConverterEvdevImpl() override {}
42 43
43 private: 44 private:
(...skipping 419 matching lines...) Expand 10 before | Expand all | Expand 10 after
463 {{0, 0}, EV_KEY, BTN_TOUCH, 1}, 464 {{0, 0}, EV_KEY, BTN_TOUCH, 1},
464 {{0, 0}, EV_SYN, SYN_REPORT, 0}, 465 {{0, 0}, EV_SYN, SYN_REPORT, 0},
465 466
466 {{0, 0}, EV_KEY, BTN_TOUCH, 0}, 467 {{0, 0}, EV_KEY, BTN_TOUCH, 0},
467 {{0, 0}, EV_SYN, SYN_REPORT, 0}, 468 {{0, 0}, EV_SYN, SYN_REPORT, 0},
468 }; 469 };
469 470
470 dev->ProcessEvents(mock_kernel_queue, arraysize(mock_kernel_queue)); 471 dev->ProcessEvents(mock_kernel_queue, arraysize(mock_kernel_queue));
471 EXPECT_EQ(0u, size()); 472 EXPECT_EQ(0u, size());
472 } 473 }
OLDNEW
« no previous file with comments | « ui/events/ozone/evdev/event_converter_evdev_impl.cc ('k') | ui/events/ozone/evdev/event_factory_evdev.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698