aboutsummaryrefslogtreecommitdiff
path: root/spawn.c
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2020-10-26 20:02:53 +0000
committerDaniel Eklöf <daniel@ekloef.se>2020-10-26 20:02:53 +0000
commit8e23b5b70d8622784e4856e5f14493a8893eab8b (patch)
tree644f42de6dd959a1eb0acc4b7837a1e836844556 /spawn.c
parentwayland: bind to data-device-manager version 3, for drag-and-drop support (diff)
selection: implement support for drag-and-drop
We accept COPY and MOVE actions, for text/plain;charset=utf-8 mime-types. To implement DnD, we need to track the current DnD data offer *and* the terminal instance it is (currently) targeting. To do this, a seat has a new member, ‘dnd_term’. On a DnD enter event, we lookup the corresponding terminal instance and point ‘dnd_term’ to it. On a DnD leave event, ‘dnd_term’ is reset. The DnD data offer is tracked in the terminal’s wayland window instance. It is reset, along with the seat’s ‘dnd_term’ on a DnD leave event. On a drop event, we immediately clear the seat’s ‘dnd_term’, to ensure we don’t reset it, or destroy the offer before the drop has been completed. The drop’s ‘done()’ callback takes care of destroying and resetting the DnD offer in the terminal’s wayland window instance. Closes #175
Diffstat (limited to 'spawn.c')
0 files changed, 0 insertions, 0 deletions