Details
-
Bug
-
Resolution: Unresolved
-
P3: Somewhat important
-
4.5.0, 4.5.1, 4.5.2, 4.5.3, 5.7.0
-
None
-
Windows XP/Vista, MS Visual Studi 2005.
Description
#include <QtGui/QApplication> #include <QMessageBox> #include <QTimer> int main(int argc, char *argv[]) { QApplication a(argc, argv); a.setQuitOnLastWindowClosed ( true ); QMessageBox w( QMessageBox::Information, QObject::tr("QMessageBox test"), QObject::tr("This message box should be closed in 5 s" )); w.setStandardButtons(QMessageBox::NoButton); w.show(); QTimer::singleShot( 5000, &w, SLOT(close()) ); return a.exec(); }
This test program never ends.
After commenting line
w.setStandardButtons(QMessageBox::NoButton);
we have QMessageBox with OK button and program ends after 5 s.
Attachments
Gerrit Reviews
For Gerrit Dashboard: QTBUG-6093 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
521243,5 | QMessageBox: Allow closing message box with no buttons | dev | qt/qtbase | Status: ABANDONED | +1 | 0 |