backend/libinput: rework tablet_pad interface

The wlr_libinput_input_device now owns its wlr_tablet_pad, instead of creating
a new wlr_libinput_input_device for it.
This commit is contained in:
Simon Zeni 2022-02-24 15:30:26 -05:00 committed by Kirill Primak
parent c8456086a1
commit 0d21496e53
4 changed files with 94 additions and 102 deletions

View file

@ -255,11 +255,10 @@ struct libinput_device *wlr_libinput_get_device_handle(
case WLR_INPUT_DEVICE_TABLET_TOOL:
dev = device_from_tablet(wlr_dev->tablet);
break;
default:
dev = (struct wlr_libinput_input_device *)wlr_dev;
case WLR_INPUT_DEVICE_TABLET_PAD:
dev = device_from_tablet_pad(wlr_dev->tablet_pad);
break;
}
return dev->handle;
}