mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2024-11-22 15:12:26 +00:00
types/wlr_tablet_tool: remove name ambiguity
It wasn't clear in the backend whether to use name or base.name, change it so base.name has to be used. Fixes https://github.com/swaywm/sway/issues/6884
This commit is contained in:
parent
13fcdba75c
commit
7a2c96dcbd
@ -836,8 +836,8 @@ static void handle_tablet_name(void *data, struct zwp_tablet_v2 *zwp_tablet_v2,
|
|||||||
struct wlr_wl_input_device *dev = data;
|
struct wlr_wl_input_device *dev = data;
|
||||||
struct wlr_tablet *tablet = dev->wlr_input_device.tablet;
|
struct wlr_tablet *tablet = dev->wlr_input_device.tablet;
|
||||||
|
|
||||||
free(tablet->name);
|
free(tablet->base.name);
|
||||||
tablet->name = strdup(name);
|
tablet->base.name = strdup(name);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void handle_tablet_id(void *data, struct zwp_tablet_v2 *zwp_tablet_v2,
|
static void handle_tablet_id(void *data, struct zwp_tablet_v2 *zwp_tablet_v2,
|
||||||
|
@ -71,7 +71,6 @@ struct wlr_tablet {
|
|||||||
struct wl_signal button;
|
struct wl_signal button;
|
||||||
} events;
|
} events;
|
||||||
|
|
||||||
char *name;
|
|
||||||
struct wl_array paths; // char *
|
struct wl_array paths; // char *
|
||||||
|
|
||||||
void *data;
|
void *data;
|
||||||
|
@ -108,9 +108,9 @@ void add_tablet_client(struct wlr_tablet_seat_client_v2 *seat,
|
|||||||
zwp_tablet_seat_v2_send_tablet_added(seat->resource, client->resource);
|
zwp_tablet_seat_v2_send_tablet_added(seat->resource, client->resource);
|
||||||
|
|
||||||
// Send the expected events
|
// Send the expected events
|
||||||
if (tablet->wlr_tablet->name) {
|
if (tablet->wlr_tablet->base.name) {
|
||||||
zwp_tablet_v2_send_name(client->resource,
|
zwp_tablet_v2_send_name(client->resource,
|
||||||
tablet->wlr_tablet->name);
|
tablet->wlr_tablet->base.name);
|
||||||
}
|
}
|
||||||
zwp_tablet_v2_send_id(client->resource,
|
zwp_tablet_v2_send_id(client->resource,
|
||||||
tablet->wlr_device->vendor, tablet->wlr_device->product);
|
tablet->wlr_device->vendor, tablet->wlr_device->product);
|
||||||
|
Loading…
Reference in New Issue
Block a user