|
|
@ -320,11 +320,12 @@ static void new_input_notify(struct wl_listener *listener, void *data) {
|
|
|
|
wl_signal_add(&device->tablet_pad->events.ring, &pstate->ring);
|
|
|
|
wl_signal_add(&device->tablet_pad->events.ring, &pstate->ring);
|
|
|
|
wl_list_insert(&sample->tablet_pads, &pstate->link);
|
|
|
|
wl_list_insert(&sample->tablet_pads, &pstate->link);
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case WLR_INPUT_DEVICE_TABLET_TOOL:
|
|
|
|
case WLR_INPUT_DEVICE_TABLET_TOOL:;
|
|
|
|
sample->width_mm = device->width_mm == 0 ?
|
|
|
|
struct wlr_tablet *tablet = device->tablet;
|
|
|
|
20 : device->width_mm;
|
|
|
|
sample->width_mm = tablet->width_mm == 0 ?
|
|
|
|
sample->height_mm = device->height_mm == 0 ?
|
|
|
|
20 : tablet->width_mm;
|
|
|
|
10 : device->height_mm;
|
|
|
|
sample->height_mm = tablet->height_mm == 0 ?
|
|
|
|
|
|
|
|
10 : tablet->height_mm;
|
|
|
|
|
|
|
|
|
|
|
|
struct tablet_tool_state *tstate = calloc(sizeof(struct tablet_tool_state), 1);
|
|
|
|
struct tablet_tool_state *tstate = calloc(sizeof(struct tablet_tool_state), 1);
|
|
|
|
tstate->device = device;
|
|
|
|
tstate->device = device;
|
|
|
@ -344,7 +345,6 @@ static void new_input_notify(struct wl_listener *listener, void *data) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
int main(int argc, char *argv[]) {
|
|
|
|
int main(int argc, char *argv[]) {
|
|
|
|
wlr_log_init(WLR_DEBUG, NULL);
|
|
|
|
wlr_log_init(WLR_DEBUG, NULL);
|
|
|
|
struct wl_display *display = wl_display_create();
|
|
|
|
struct wl_display *display = wl_display_create();
|
|
|
|