mirror of
https://gitlab.freedesktop.org/wayland/wayland.git
synced 2025-11-04 13:29:51 -05:00
server: fix event sending type mismatches
These were not bugs in practice, because the first (and only) field of struct wl_surface is struct wl_resource. Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
This commit is contained in:
parent
5ee70146c6
commit
70db367ccc
2 changed files with 7 additions and 5 deletions
|
|
@ -581,14 +581,15 @@ wl_input_device_set_pointer_focus(struct wl_input_device *device,
|
|||
if (device->pointer_focus_resource) {
|
||||
wl_input_device_send_pointer_leave(
|
||||
device->pointer_focus_resource,
|
||||
time, device->pointer_focus);
|
||||
time, &device->pointer_focus->resource);
|
||||
wl_list_remove(&device->pointer_focus_listener.link);
|
||||
}
|
||||
|
||||
resource = find_resource_for_surface(&device->resource_list, surface);
|
||||
if (resource) {
|
||||
wl_input_device_send_pointer_enter(resource, time,
|
||||
surface, sx, sy);
|
||||
&surface->resource,
|
||||
sx, sy);
|
||||
wl_list_insert(resource->destroy_listener_list.prev,
|
||||
&device->pointer_focus_listener.link);
|
||||
}
|
||||
|
|
@ -612,14 +613,15 @@ wl_input_device_set_keyboard_focus(struct wl_input_device *device,
|
|||
if (device->keyboard_focus_resource) {
|
||||
wl_input_device_send_keyboard_leave(
|
||||
device->keyboard_focus_resource,
|
||||
time, device->keyboard_focus);
|
||||
time, &device->keyboard_focus->resource);
|
||||
wl_list_remove(&device->keyboard_focus_listener.link);
|
||||
}
|
||||
|
||||
resource = find_resource_for_surface(&device->resource_list, surface);
|
||||
if (resource) {
|
||||
wl_input_device_send_keyboard_enter(resource, time,
|
||||
surface, &device->keys);
|
||||
&surface->resource,
|
||||
&device->keys);
|
||||
wl_list_insert(resource->destroy_listener_list.prev,
|
||||
&device->keyboard_focus_listener.link);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue