c++ - Dragging an image from Chrome to a Qt application -
i trying data image dragged directly browser qt app. have following code:
void myview::dropevent( qdropevent* event ) { qgraphicsview::dropevent( event ); if ( event->mimedata()->hasimage() ) { qimage image = qvariant_cast<qimage>( event->mimedata()->imagedata() ); ...
this works fine firefox (windows/mac), safari (mac) , ie (windows). qmimedata::hasurl() returns false chrome on both windows , mac.
on further investigation qt expects image data in mime format "application/x-qt-image". seems chrome doesn't provide this. there workaround chrome? haven't been able find anything.
Comments
Post a Comment