aboutsummaryrefslogtreecommitdiff
path: root/backend/libinput/tablet_pad.c
diff options
context:
space:
mode:
authorDominique Martinet <asmadeus@codewreck.org>2017-08-14 15:59:59 +0200
committerDominique Martinet <asmadeus@codewreck.org>2017-08-14 16:22:31 +0200
commita289940bff8bcda5cc6aeb1d88f4f1e5c2c38317 (patch)
treed9b9c318b7140a191a5d27f0dbeb1db2deb08cfd /backend/libinput/tablet_pad.c
parent53e7bebd2381318b9edcbc8d305d4ec2bed9b3ce (diff)
Refactor out wlr_tablet_pad_state
Diffstat (limited to 'backend/libinput/tablet_pad.c')
-rw-r--r--backend/libinput/tablet_pad.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/backend/libinput/tablet_pad.c b/backend/libinput/tablet_pad.c
index 9713bb1d..efad1068 100644
--- a/backend/libinput/tablet_pad.c
+++ b/backend/libinput/tablet_pad.c
@@ -10,7 +10,13 @@
struct wlr_tablet_pad *wlr_libinput_tablet_pad_create(
struct libinput_device *libinput_dev) {
assert(libinput_dev);
- return wlr_tablet_pad_create(NULL, NULL);
+ struct wlr_tablet_pad *wlr_tablet_pad = calloc(1, sizeof(struct wlr_tablet_pad));
+ if (!wlr_tablet_pad) {
+ wlr_log(L_ERROR, "Unable to allocate wlr_tablet_pad");
+ return NULL;
+ }
+ wlr_tablet_pad_init(wlr_tablet_pad, NULL);
+ return wlr_tablet_pad;
}
void handle_tablet_pad_button(struct libinput_event *event,