17 qDebug( ) <<
"drop event " << event;
18 qDebug( ) <<
"text?" <<
event->mimeData( )->text( );
20 if( event->mimeData( )->hasText( ) ) {
21 QString text =
event->mimeData( )->text( );
22 if( text ==
"item" or text ==
"item2" ) {
25 QString filePath = text.remove(
"file:///" );
27 QFileInfo info( filePath );
28 if( info.isFile( ) ) {
29 emit
pixmap( QPixmap( filePath ) );
32 emit
file( filePath );