Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-36958

Windows: QMimeData::retrieveData() on mime data set on the clipboard is called after destruction of Q[Gui]Application, causing problems when setting QPixmap/QImage data

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P2: Important
    • Resolution: Done
    • Affects Version/s: 4.8.6, 5.3.0
    • Fix Version/s: 5.3.0
    • Component/s: GUI: Drag and Drop
    • Labels:
      None
    • Environment:
      Windows
    • Commits:
      42afcfd8ce2fec86836d2414ee1e6d88f42613f3 (dev 21.2.2014, 5.3)

      Description

      Steps to reproduce (qtbug36958.zip):

      • Launch app, press "Copy Custom Mime DAta"
      • Quit
        Note assert:
        MyDialog::MyDialog
        MyMimeData::MyMimeData
        MyDialog::slotCopyCustomMimeData QMimeData(0x5c032f0590)
        MyMimeData::formats ("application/x-qt-image")
        MyMimeData::retrieveData "application/x-qt-image" QVariant::QImage
        MyMimeData::retrieveData returns QVariant(QPixmap, QPixmap(QSize(32, 32) )  )
        MyMimeData::formats ("application/x-qt-image")
        MyDialog::~MyDialog
        MyMimeData::formats ("application/x-qt-image")
        MyMimeData::retrieveData "application/x-qt-image" QVariant::QImage
        QCoreApplication::arguments: Please instantiate the QApplication object first
        QPixmap: Must construct a QGuiApplication before a QPixmap
        

        Same problem exists in Qt 4, but it does not crash.

        Attachments

          Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            Activity

              People

              Assignee:
              kleint Friedemann Kleint
              Reporter:
              kleint Friedemann Kleint
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes