xwayland: Implement X11-to-wayland DnD

Desktop / GNOME / Mutter - Carlos Garnacho [gnome.org] - 29 May 2015 04:27 UTC

When DnD is started from an X11 client, mutter now sets up an special grab that 1) Ensures the drag source keeps receiving events, and 2) Moves an internal X Window over wayland clients as soon as the pointer enters over these.

That window will act as the X-side peer for the currently focused wayland client, and will transform XdndEnter/Position/Leave/Drop messages into wayland actions. If DnD happens between X11 clients, the window will be moved away and unmapped, to let these operate as usual.

https://bugzilla.gnome.org/show_bug.cgi?id=738312

4a968c3 xwayland: Implement X11-to-wayland DnD
src/wayland/meta-wayland-data-device.c | 156 +++++++++------
src/wayland/meta-wayland-data-device.h | 14 ++
src/wayland/meta-xwayland-selection.c | 334 ++++++++++++++++++++++++++++++--
3 files changed, 434 insertions(+), 70 deletions(-)

Upstream: git.gnome.org


  • Share