16 class Drop :
public QLabel {
22 if (pe->mimeData()->hasFormat(
"text/uri-list")) {
23 pe->acceptProposedAction();
29 QList<QUrl> urlList = pe->mimeData()->urls();
31 foreach(QUrl url, urlList) {
32 str += url.toString() +
"\n";
34 setText(
"Dropped:\n" + str);
38 Drop(QWidget* pwgt = 0) : QLabel(
"Drop Area", pwgt)
virtual void dropEvent(QDropEvent *pe)
virtual void dragEnterEvent(QDragEnterEvent *pe)