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
3 # found in the LICENSE file.
5 import("//build/config/features.gni")
6 import("//build/config/linux/pkg_config.gni")
7 import("//build/config/ui.gni")
10 # Optional system libraries.
15 pkg_config("xkbcommon") {
16 packages = [ "xkbcommon" ]
20 component("events_ozone") {
22 "chromeos/cursor_controller.cc",
23 "chromeos/cursor_controller.h",
24 "device/device_event.cc",
25 "device/device_event.h",
26 "device/device_event_observer.h",
27 "device/device_manager.cc",
28 "device/device_manager.h",
29 "device/device_manager_manual.cc",
30 "device/device_manager_manual.h",
31 "device/udev/device_manager_udev.cc",
32 "device/udev/device_manager_udev.h",
33 "events_ozone_export.h",
38 "//base/third_party/dynamic_annotations",
40 "//ui/events:events_base",
43 defines = [ "EVENTS_OZONE_IMPLEMENTATION" ]
47 "device/udev/device_manager_udev.cc",
48 "device/udev/device_manager_udev.h",
52 if (use_ozone_evdev && use_udev) {
53 deps += [ "//device/udev_linux" ]
58 defines = [ "USE_EVDEV" ]
61 config("evdev_gestures") {
62 defines = [ "USE_EVDEV_GESTURES" ]
65 component("events_ozone_evdev") {
67 "evdev/device_event_dispatcher_evdev.cc",
68 "evdev/device_event_dispatcher_evdev.h",
69 "evdev/event_converter_evdev.cc",
70 "evdev/event_converter_evdev.h",
71 "evdev/event_converter_evdev_impl.cc",
72 "evdev/event_converter_evdev_impl.h",
73 "evdev/event_device_info.cc",
74 "evdev/event_device_info.h",
75 "evdev/event_factory_evdev.cc",
76 "evdev/event_factory_evdev.h",
77 "evdev/event_modifiers_evdev.cc",
78 "evdev/event_modifiers_evdev.h",
79 "evdev/event_thread_evdev.cc",
80 "evdev/event_thread_evdev.h",
81 "evdev/events_ozone_evdev_export.h",
82 "evdev/input_controller_evdev.cc",
83 "evdev/input_controller_evdev.h",
84 "evdev/input_device_factory_evdev.cc",
85 "evdev/input_device_factory_evdev.h",
86 "evdev/input_device_factory_evdev_proxy.cc",
87 "evdev/input_device_factory_evdev_proxy.h",
88 "evdev/input_device_settings_evdev.cc",
89 "evdev/input_device_settings_evdev.h",
90 "evdev/input_injector_evdev.cc",
91 "evdev/input_injector_evdev.h",
92 "evdev/keyboard_evdev.cc",
93 "evdev/keyboard_evdev.h",
94 "evdev/keyboard_util_evdev.cc",
95 "evdev/keyboard_util_evdev.h",
96 "evdev/mouse_button_map_evdev.cc",
97 "evdev/mouse_button_map_evdev.h",
98 "evdev/tablet_event_converter_evdev.cc",
99 "evdev/tablet_event_converter_evdev.h",
100 "evdev/touch_evdev_debug_buffer.cc",
101 "evdev/touch_evdev_debug_buffer.h",
102 "evdev/touch_evdev_types.cc",
103 "evdev/touch_evdev_types.h",
104 "evdev/touch_event_converter_evdev.cc",
105 "evdev/touch_event_converter_evdev.h",
106 "evdev/touch_noise/far_apart_taps_touch_noise_filter.cc",
107 "evdev/touch_noise/far_apart_taps_touch_noise_filter.h",
108 "evdev/touch_noise/horizontally_aligned_touch_noise_filter.cc",
109 "evdev/touch_noise/horizontally_aligned_touch_noise_filter.h",
110 "evdev/touch_noise/single_position_touch_noise_filter.cc",
111 "evdev/touch_noise/single_position_touch_noise_filter.h",
112 "evdev/touch_noise/touch_noise_filter.h",
113 "evdev/touch_noise/touch_noise_finder.cc",
114 "evdev/touch_noise/touch_noise_finder.h",
117 defines = [ "EVENTS_OZONE_EVDEV_IMPLEMENTATION" ]
121 ":events_ozone_layout",
124 "//ui/events:dom_keycode_converter",
125 "//ui/events:events_base",
126 "//ui/events/devices",
127 "//ui/events/platform",
131 public_configs = [ ":evdev" ]
133 if (use_ozone_evdev && use_evdev_gestures) {
135 "evdev/libgestures_glue/event_reader_libevdev_cros.cc",
136 "evdev/libgestures_glue/event_reader_libevdev_cros.h",
137 "evdev/libgestures_glue/gesture_feedback.cc",
138 "evdev/libgestures_glue/gesture_feedback.h",
139 "evdev/libgestures_glue/gesture_interpreter_libevdev_cros.cc",
140 "evdev/libgestures_glue/gesture_interpreter_libevdev_cros.h",
141 "evdev/libgestures_glue/gesture_logging.cc",
142 "evdev/libgestures_glue/gesture_logging.h",
143 "evdev/libgestures_glue/gesture_property_provider.cc",
144 "evdev/libgestures_glue/gesture_property_provider.h",
145 "evdev/libgestures_glue/gesture_timer_provider.cc",
146 "evdev/libgestures_glue/gesture_timer_provider.h",
149 public_configs += [ ":evdev_gestures" ]
152 "//build/config/linux:libevdev-cros",
153 "//build/config/linux:libgestures",
158 config("events_ozone_layout_config") {
160 defines = [ "USE_XKBCOMMON" ]
164 component("events_ozone_layout") {
166 "layout/events_ozone_layout_export.h",
167 "layout/keyboard_layout_engine.h",
168 "layout/keyboard_layout_engine_manager.cc",
169 "layout/keyboard_layout_engine_manager.h",
170 "layout/layout_util.cc",
171 "layout/layout_util.h",
172 "layout/no/no_keyboard_layout_engine.cc",
173 "layout/no/no_keyboard_layout_engine.h",
174 "layout/stub/stub_keyboard_layout_engine.cc",
175 "layout/stub/stub_keyboard_layout_engine.h",
178 defines = [ "EVENTS_OZONE_LAYOUT_IMPLEMENTATION" ]
182 "//ui/events:dom_keycode_converter",
183 "//ui/events:events_base",
186 public_configs = [ ":events_ozone_layout_config" ]
189 configs += [ ":xkbcommon" ]
192 "layout/xkb/scoped_xkb.h",
194 "layout/xkb/xkb_evdev_codes.cc",
195 "layout/xkb/xkb_evdev_codes.h",
196 "layout/xkb/xkb_key_code_converter.h",
197 "layout/xkb/xkb_keyboard_code_conversion.cc",
198 "layout/xkb/xkb_keyboard_code_conversion.h",
199 "layout/xkb/xkb_keyboard_layout_engine.cc",
200 "layout/xkb/xkb_keyboard_layout_engine.h",
201 "layout/xkb/xkb_keysym.h",