backends/x11: Touch support

Closes #1749
This commit is contained in:
Sebastian Krzyszkowiak 2019-07-15 23:36:21 +02:00 committed by Drew DeVault
parent 2d4bc66f11
commit 415267ac13
3 changed files with 143 additions and 1 deletions

View file

@ -31,12 +31,22 @@ struct wlr_x11_output {
struct wlr_pointer pointer;
struct wlr_input_device pointer_dev;
struct wlr_touch touch;
struct wlr_input_device touch_dev;
struct wl_list touchpoints; // wlr_x11_touchpoint::link
struct wl_event_source *frame_timer;
int frame_delay;
bool cursor_hidden;
};
struct wlr_x11_touchpoint {
uint32_t x11_id;
int wayland_id;
struct wl_list link; // wlr_x11_output::touch_points
};
struct wlr_x11_backend {
struct wlr_backend backend;
struct wl_display *wl_display;
@ -79,6 +89,7 @@ struct wlr_x11_output *get_x11_output_from_window_id(
extern const struct wlr_keyboard_impl keyboard_impl;
extern const struct wlr_pointer_impl pointer_impl;
extern const struct wlr_touch_impl touch_impl;
extern const struct wlr_input_device_impl input_device_impl;
void handle_x11_xinput_event(struct wlr_x11_backend *x11,