[Qt-interest] Show Open-File-dialog on startup
Oliver Demetz
forenbeitraege at oliverdemetz.de
Tue Mar 24 14:43:47 CET 2009
Hi!
My main widget is derived from QWidget
class MainWidget : public QWidget
{
MainWidget()
{
//bla...inititialisations
load();
};
public slots:
void load(void)
{
QString filename = QFileDialog::getOpenFileName(this,
tr("Open File"), "", tr("PNGs (*.png)"));
// and so on...
};
}
This construction leads to an immediate program abort with message:
Fatal: ASSERT: "!parent ||parent->testAttribute(Qt::WA_WState_Created)"
in file dialogs\qfiledialog_win.cpp, line 309
Is there a signal being emitted after everything has been created that I
could connect to the load-slot?
Thanks in advance,
Oliver
More information about the Qt-interest-old
mailing list