OLD | NEW |
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 "ui/events/x/device_data_manager_x11.h" | 5 #include "ui/events/x/device_data_manager_x11.h" |
6 | 6 |
7 #include <X11/extensions/XInput.h> | 7 #include <X11/extensions/XInput.h> |
8 #include <X11/extensions/XInput2.h> | 8 #include <X11/extensions/XInput2.h> |
9 #include <X11/Xlib.h> | 9 #include <X11/Xlib.h> |
10 | 10 |
11 #include "base/logging.h" | 11 #include "base/logging.h" |
12 #include "base/memory/singleton.h" | 12 #include "base/memory/singleton.h" |
13 #include "base/sys_info.h" | 13 #include "base/sys_info.h" |
14 #include "ui/events/event_constants.h" | 14 #include "ui/events/event_constants.h" |
15 #include "ui/events/event_switches.h" | 15 #include "ui/events/event_switches.h" |
16 #include "ui/events/keycodes/keyboard_code_conversion_x.h" | 16 #include "ui/events/keycodes/keyboard_code_conversion_x.h" |
17 #include "ui/events/x/device_list_cache_x.h" | 17 #include "ui/events/x/device_list_cache_x.h" |
18 #include "ui/events/x/touch_factory_x11.h" | 18 #include "ui/events/x/touch_factory_x11.h" |
19 #include "ui/gfx/display.h" | 19 #include "ui/gfx/display.h" |
20 #include "ui/gfx/point3_f.h" | 20 #include "ui/gfx/geometry/point3_f.h" |
21 #include "ui/gfx/x/x11_types.h" | 21 #include "ui/gfx/x/x11_types.h" |
22 | 22 |
23 // XIScrollClass was introduced in XI 2.1 so we need to define it here | 23 // XIScrollClass was introduced in XI 2.1 so we need to define it here |
24 // for backward-compatibility with older versions of XInput. | 24 // for backward-compatibility with older versions of XInput. |
25 #if !defined(XIScrollClass) | 25 #if !defined(XIScrollClass) |
26 #define XIScrollClass 3 | 26 #define XIScrollClass 3 |
27 #endif | 27 #endif |
28 | 28 |
29 // Multi-touch support was introduced in XI 2.2. Add XI event types here | 29 // Multi-touch support was introduced in XI 2.2. Add XI event types here |
30 // for backward-compatibility with older versions of XInput. | 30 // for backward-compatibility with older versions of XInput. |
(...skipping 672 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
703 case GenericEvent: | 703 case GenericEvent: |
704 return blocked_devices_.test( | 704 return blocked_devices_.test( |
705 static_cast<XIDeviceEvent*>(native_event->xcookie.data)->sourceid); | 705 static_cast<XIDeviceEvent*>(native_event->xcookie.data)->sourceid); |
706 default: | 706 default: |
707 break; | 707 break; |
708 } | 708 } |
709 return false; | 709 return false; |
710 } | 710 } |
711 | 711 |
712 } // namespace ui | 712 } // namespace ui |
OLD | NEW |