aboutsummaryrefslogtreecommitdiff
path: root/include/backend
diff options
context:
space:
mode:
authorSimon Zeni <simon@bl4ckb0ne.ca>2022-02-24 11:00:11 -0500
committerKirill Primak <vyivel@eclair.cafe>2022-03-02 18:18:05 +0000
commitc8456086a164fd62c26fe3f3ade5f1e59d25eda0 (patch)
tree46956351eb341cd1a943dbe082d9dd6b0a16e69a /include/backend
parent4f4dd9522378f4d62a47ee9b1472378c9960b2f2 (diff)
backend/libinput: rework tablet interface
The wlr_libinput_device owns its wlr_tablet and its associated wlr_tablet_tools
Diffstat (limited to 'include/backend')
-rw-r--r--include/backend/libinput.h15
1 files changed, 9 insertions, 6 deletions
diff --git a/include/backend/libinput.h b/include/backend/libinput.h
index c8719af3..808da101 100644
--- a/include/backend/libinput.h
+++ b/include/backend/libinput.h
@@ -38,6 +38,8 @@ struct wlr_libinput_input_device {
struct wlr_pointer pointer;
struct wlr_switch switch_device;
struct wlr_touch touch;
+ struct wlr_tablet tablet;
+ struct wl_list tablet_tools; // see backend/libinput/tablet_tool.c
struct wl_list link;
};
@@ -111,16 +113,17 @@ void handle_touch_cancel(struct libinput_event *event,
void handle_touch_frame(struct libinput_event *event,
struct wlr_touch *touch);
-struct wlr_tablet *create_libinput_tablet(
- struct libinput_device *device);
+void init_device_tablet(struct wlr_libinput_input_device *dev);
+struct wlr_libinput_input_device *device_from_tablet(
+ struct wlr_tablet *tablet);
void handle_tablet_tool_axis(struct libinput_event *event,
- struct libinput_device *device);
+ struct wlr_tablet *tablet);
void handle_tablet_tool_proximity(struct libinput_event *event,
- struct libinput_device *device);
+ struct wlr_tablet *tablet);
void handle_tablet_tool_tip(struct libinput_event *event,
- struct libinput_device *device);
+ struct wlr_tablet *tablet);
void handle_tablet_tool_button(struct libinput_event *event,
- struct libinput_device *device);
+ struct wlr_tablet *tablet);
struct wlr_tablet_pad *create_libinput_tablet_pad(
struct libinput_device *device);