WIP: Implement drag and drop support for icon widget
Review Request #124472 - Created July 26, 2015 and submitted
|Kai Uwe Broulik|
Brings back the ability to drop files onto a icon widget and have the associated application open it. Dropping something onto a folder does not yet work because it should use the konq menu thingie (Copy/Move/Link) but I don't want yet another copy of that (there's one in the folderview containment).
It should probably check already on drag enter whether it's a viable drop target (eg. executable or folder), also do some coding style cleanups I thought I had already committed earlier.
Dragged Gwenview onto the desktop, an icon was created.
Dropped one picture onto it, Gwenview opened it.
Dropped two pictures onto, Gwenview showed both.
- Check application supported mime types
- Set plasmoid title and icon (this way when removing the widget the undo notification shows the proper app name and icon)
Revision 2 (+121 -41)
Status: Closed (submitted)
Submitted with commit 5f8051324985d9fb14bccfa0a4ecda9830aeb143 by Kai Uwe Broulik to branch master.
QUrl::fromUserInput(droppedUrl.toString(), QString() QUrl::AssumeLocalFile) maybe?
Make use of your stringUrl ;)
The drop urls thingie from Dolphin (without Arks dndextract service):
KIO::DropJob *job = KIO::drop(QDropEvent *, m_url);
KJobWidgets::setWindow(job, QWidget *);
Is this what you want? :)
And thanks for this nice feature :)