diff options
author | pkotwicz <pkotwicz@chromium.org> | 2015-03-23 15:24:22 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-03-23 22:24:45 +0000 |
commit | db90ae3b7c639a5fcedd831eb07db9fa8625dff5 (patch) | |
tree | 58ab82672b72b0eb4940bdcc503de81b557ef610 /ui | |
parent | a5fd5e57db1e46041ca9bccc8ff057c118e062e7 (diff) | |
download | chromium_src-db90ae3b7c639a5fcedd831eb07db9fa8625dff5.zip chromium_src-db90ae3b7c639a5fcedd831eb07db9fa8625dff5.tar.gz chromium_src-db90ae3b7c639a5fcedd831eb07db9fa8625dff5.tar.bz2 |
Remove support for type A touchscreens from TouchEventConverterEvdev
BUG=None
TEST=None
Review URL: https://codereview.chromium.org/1022673006
Cr-Commit-Position: refs/heads/master@{#321875}
Diffstat (limited to 'ui')
3 files changed, 0 insertions, 36 deletions
diff --git a/ui/events/ozone/evdev/touch_event_converter_evdev.cc b/ui/events/ozone/evdev/touch_event_converter_evdev.cc index 3aaaa31..2be21ce 100644 --- a/ui/events/ozone/evdev/touch_event_converter_evdev.cc +++ b/ui/events/ozone/evdev/touch_event_converter_evdev.cc @@ -80,7 +80,6 @@ TouchEventConverterEvdev::TouchEventConverterEvdev( : EventConverterEvdev(fd, path, id, type), dispatcher_(dispatcher), syn_dropped_(false), - is_type_a_(false), touch_points_(0), current_slot_(0) { } @@ -255,16 +254,6 @@ void TouchEventConverterEvdev::ProcessSyn(const input_event& input) { } else { ReportEvents(EventConverterEvdev::TimeDeltaFromInputEvent(input)); } - if (is_type_a_) - current_slot_ = 0; - break; - case SYN_MT_REPORT: - // For type A devices, we just get a stream of all current contacts, - // in some arbitrary order. - events_[current_slot_].type_ = ET_TOUCH_PRESSED; - if (events_.size() - 1 > current_slot_) - current_slot_++; - is_type_a_ = true; break; case SYN_DROPPED: // Some buffer has overrun. We ignore all events up to and diff --git a/ui/events/ozone/evdev/touch_event_converter_evdev.h b/ui/events/ozone/evdev/touch_event_converter_evdev.h index f522921..f25ec7e 100644 --- a/ui/events/ozone/evdev/touch_event_converter_evdev.h +++ b/ui/events/ozone/evdev/touch_event_converter_evdev.h @@ -77,9 +77,6 @@ class EVENTS_OZONE_EVDEV_EXPORT TouchEventConverterEvdev // Set if we have seen a SYN_DROPPED and not yet re-synced with the device. bool syn_dropped_; - // Set if this is a type A device (uses SYN_MT_REPORT). - bool is_type_a_; - // Pressure values. int pressure_min_; int pressure_max_; // Used to normalize pressure values. diff --git a/ui/events/ozone/evdev/touch_event_converter_evdev_unittest.cc b/ui/events/ozone/evdev/touch_event_converter_evdev_unittest.cc index eaec9b1..c6d93c4 100644 --- a/ui/events/ozone/evdev/touch_event_converter_evdev_unittest.cc +++ b/ui/events/ozone/evdev/touch_event_converter_evdev_unittest.cc @@ -448,28 +448,6 @@ TEST_F(TouchEventConverterEvdevTest, TwoFingerGesture) { EXPECT_FLOAT_EQ(.5f, ev1.pressure); } -TEST_F(TouchEventConverterEvdevTest, TypeA) { - ui::MockTouchEventConverterEvdev* dev = device(); - - struct input_event mock_kernel_queue_press0[] = { - {{0, 0}, EV_ABS, ABS_MT_TOUCH_MAJOR, 3}, - {{0, 0}, EV_ABS, ABS_MT_PRESSURE, 45}, - {{0, 0}, EV_ABS, ABS_MT_POSITION_X, 42}, - {{0, 0}, EV_ABS, ABS_MT_POSITION_Y, 51}, - {{0, 0}, EV_SYN, SYN_MT_REPORT, 0}, - {{0, 0}, EV_ABS, ABS_MT_PRESSURE, 45}, - {{0, 0}, EV_ABS, ABS_MT_POSITION_X, 61}, - {{0, 0}, EV_ABS, ABS_MT_POSITION_Y, 71}, - {{0, 0}, EV_SYN, SYN_MT_REPORT, 0}, - {{0, 0}, EV_SYN, SYN_REPORT, 0} - }; - - // Check that two events are generated. - dev->ConfigureReadMock(mock_kernel_queue_press0, 10, 0); - dev->ReadNow(); - EXPECT_EQ(2u, size()); -} - TEST_F(TouchEventConverterEvdevTest, Unsync) { ui::MockTouchEventConverterEvdev* dev = device(); |