1
0
Fork 0

data-device: Set "dnd" role on the icon surface, not the source one

The DnD source surface evidently has other role assigned, it's the
icon surface which is supposed to be a fresh one.
This commit is contained in:
Carlos Garnacho 2015-02-18 16:44:14 +01:00
parent 673ddfde04
commit 469b85eb7c

View file

@ -410,7 +410,8 @@ data_device_start_drag (struct wl_client *client,
seat->pointer.grab != &seat->pointer.default_grab)
return;
if (meta_wayland_surface_set_role (surface,
if (icon_resource &&
meta_wayland_surface_set_role (wl_resource_get_user_data (icon_resource),
META_WAYLAND_SURFACE_ROLE_DND,
resource,
WL_DATA_DEVICE_ERROR_ROLE) != 0)