seat: re-map tablet to output on output change

This commit is contained in:
Jens Peters 2024-01-09 06:58:35 +01:00 committed by Johan Malm
parent 8de5d7e653
commit 17e15ed987
3 changed files with 18 additions and 0 deletions

View file

@ -643,3 +643,18 @@ seat_reset_pressed(struct seat *seat)
seat->pressed.toplevel = NULL;
seat->pressed.resize_edges = 0;
}
void
seat_output_layout_changed(struct seat *seat)
{
struct input *input = NULL;
wl_list_for_each(input, &seat->inputs, link) {
switch (input->wlr_input_device->type) {
case WLR_INPUT_DEVICE_TABLET_TOOL:
map_input_to_output(seat, input->wlr_input_device, rc.tablet.output_name);
break;
default:
break;
}
}
}