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

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

Issue 561243002: ozone: evdev: Move read polling into EventConverterEvdev (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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
« no previous file with comments | « ui/events/ozone/evdev/touch_event_converter_evdev.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 <fcntl.h> 6 #include <fcntl.h>
7 #include <linux/input.h> 7 #include <linux/input.h>
8 #include <unistd.h> 8 #include <unistd.h>
9 9
10 #include <vector> 10 #include <vector>
11 11
12 #include "base/bind.h"
12 #include "base/memory/scoped_ptr.h" 13 #include "base/memory/scoped_ptr.h"
13 #include "base/memory/scoped_vector.h" 14 #include "base/memory/scoped_vector.h"
14 #include "base/posix/eintr_wrapper.h" 15 #include "base/posix/eintr_wrapper.h"
15 #include "base/run_loop.h" 16 #include "base/run_loop.h"
16 #include "base/time/time.h" 17 #include "base/time/time.h"
17 #include "testing/gtest/include/gtest/gtest.h" 18 #include "testing/gtest/include/gtest/gtest.h"
18 #include "ui/events/event.h" 19 #include "ui/events/event.h"
19 #include "ui/events/ozone/evdev/touch_event_converter_evdev.h" 20 #include "ui/events/ozone/evdev/touch_event_converter_evdev.h"
20 #include "ui/events/platform/platform_event_dispatcher.h" 21 #include "ui/events/platform/platform_event_dispatcher.h"
21 #include "ui/events/platform/platform_event_source.h" 22 #include "ui/events/platform/platform_event_source.h"
(...skipping 496 matching lines...) Expand 10 before | Expand all | Expand 10 after
518 EXPECT_EQ(0, ev0->touch_id()); 519 EXPECT_EQ(0, ev0->touch_id());
519 EXPECT_EQ(999, ev0->x()); 520 EXPECT_EQ(999, ev0->x());
520 EXPECT_EQ(888, ev0->y()); 521 EXPECT_EQ(888, ev0->y());
521 EXPECT_FLOAT_EQ(0.8333333f, ev0->force()); 522 EXPECT_FLOAT_EQ(0.8333333f, ev0->force());
522 523
523 EXPECT_EQ(1, ev1->touch_id()); 524 EXPECT_EQ(1, ev1->touch_id());
524 EXPECT_EQ(777, ev1->x()); 525 EXPECT_EQ(777, ev1->x());
525 EXPECT_EQ(666, ev1->y()); 526 EXPECT_EQ(666, ev1->y());
526 EXPECT_FLOAT_EQ(0.4666666f, ev1->force()); 527 EXPECT_FLOAT_EQ(0.4666666f, ev1->force());
527 } 528 }
OLDNEW
« no previous file with comments | « ui/events/ozone/evdev/touch_event_converter_evdev.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698