drag/drop into dolphin window - help?

Robby Stephenson robby at periapsis.org
Thu Nov 11 02:17:10 GMT 2021


Hi all,

I wonder if someone might be able to help figure out what I'm doing wrong
with regard to dragging and dropping an image into a dolphin window, trying
to get it saved as a new file. I've been using this code in Tellico, and
I'm pretty sure it used to work a while ago, but I'm not sure when it
stopped.

I made a short test case in https://invent.kde.org/rstephenson/dragdroptest
where I essentially show a widget that creates a QDrag object with image
data. I drag/drop that into a Dolphin window, and I get a dialog box
asking for a file name and to choose the data format. No matter what format
I choose, the file is never created.

>From debugging, it looks like the QMimeData inside the KIO::DropJob has
zero bytes for any data requested which is why the file is never created.
But now I'm at a dead-end - can anyone give me a pointer or suggestion as
to why that might be the case?

Relevant Tellico code is at
https://invent.kde.org/office/tellico/-/blob/master/src/gui/imagewidget.cpp#L448
but I did reduce it to a short test case, available in
https://invent.kde.org/rstephenson/dragdroptest

Thanks!
Robby
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-devel/attachments/20211110/db10d28f/attachment.htm>


More information about the kde-devel mailing list