[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: dired-mouse-drag-files
From: |
Po Lu |
Subject: |
Re: dired-mouse-drag-files |
Date: |
Sun, 10 Apr 2022 09:04:29 +0800 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux) |
[You forgot to copy in the list, I did that for you this time.]
Justus-dev@Piater.name writes:
> What about Wayland?
>
> I don't think this should be too hard to implement (famous last words).
> Perhaps I'll give it a shot myself. Any advice?
>
> Best,
> Justus
It shouldn't be too hard, thanks! First, rewrite pgtkselect.c to use
the low-level GDK selections API (the code translates very neatly from
X), since the GTK clipboard API is not very suitable for Emacs
drag-and-drop. The file that needs work is pgtkselect.c.
Then, implement `x-begin-drag' using the GDK drag-and-drop system. I
suggest running a nested event loop until the drop completes.
Most of the low level functions there are not much higher level than the
functions `x_dnd_get_target_window' and `x_set_dnd_targets' on X.
This documentation should be fairly helpful:
https://developer-old.gnome.org/gdk3/stable/gdk3-Drag-and-Drop.html
https://developer-old.gnome.org/gdk3/stable/gdk3-Selections.html
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: dired-mouse-drag-files,
Po Lu <=