diff --git a/src/wayland/meta-wayland-data-device.c b/src/wayland/meta-wayland-data-device.c index 53477a533..08940c94b 100644 --- a/src/wayland/meta-wayland-data-device.c +++ b/src/wayland/meta-wayland-data-device.c @@ -334,9 +334,9 @@ meta_wayland_data_source_set_actions (MetaWaylandDataSource *source, priv->actions_set = TRUE; } -static void -meta_wayland_data_source_set_user_action (MetaWaylandDataSource *source, - enum wl_data_device_manager_dnd_action action) +void +meta_wayland_data_source_set_user_action (MetaWaylandDataSource *source, + uint32_t action) { MetaWaylandDataSourcePrivate *priv = meta_wayland_data_source_get_instance_private (source); diff --git a/src/wayland/meta-wayland-data-device.h b/src/wayland/meta-wayland-data-device.h index c61c241a5..027dafc54 100644 --- a/src/wayland/meta-wayland-data-device.h +++ b/src/wayland/meta-wayland-data-device.h @@ -121,6 +121,8 @@ uint32_t meta_wayland_data_source_get_current_action (MetaWaylandDataSource *sou void meta_wayland_data_source_set_actions (MetaWaylandDataSource *source, uint32_t dnd_actions); +void meta_wayland_data_source_set_user_action (MetaWaylandDataSource *source, + uint32_t action); void meta_wayland_data_source_set_current_action (MetaWaylandDataSource *source, uint32_t action); diff --git a/src/wayland/meta-xwayland-dnd.c b/src/wayland/meta-xwayland-dnd.c index 31c97da19..7169ca2d9 100644 --- a/src/wayland/meta-xwayland-dnd.c +++ b/src/wayland/meta-xwayland-dnd.c @@ -787,6 +787,10 @@ meta_xwayland_dnd_handle_client_message (MetaWaylandCompositor *compositor, xdnd_atoms[ATOM_DND_TYPE_LIST]); } + meta_wayland_data_source_set_actions (dnd->source, + WL_DATA_DEVICE_MANAGER_DND_ACTION_COPY | + WL_DATA_DEVICE_MANAGER_DND_ACTION_MOVE | + WL_DATA_DEVICE_MANAGER_DND_ACTION_ASK); meta_wayland_drag_grab_set_focus (drag_grab, dnd->focus_surface); return TRUE; } @@ -806,7 +810,7 @@ meta_xwayland_dnd_handle_client_message (MetaWaylandCompositor *compositor, clutter_event_set_time (motion, dnd->last_motion_time); action = atom_to_action ((Atom) event->data.l[4]); - meta_wayland_data_source_set_actions (dnd->source, action); + meta_wayland_data_source_set_user_action (dnd->source, action); meta_wayland_surface_drag_dest_motion (drag_focus, motion); xdnd_send_status (dnd, (Window) event->data.l[0],