[Interest] App. is running after an exception is thrown.

Alexander Syvak alexander.svk at gmail.com
Fri Jul 26 20:19:58 CEST 2013


Hello,

after calling w.show() there's method redefined void event_dlg::showEvent(
QShowEvent *). In this method there's an exception thrown. The process does
not terminate.
Can anyone througly explain why is the job running after calling either
close() of the only one and thus the last window (event_dlg w) or quit() of
the QApplication a?

#include "event_dlg.h"

#include <QApplication>

#include <QMessageBox>

#include <QDebug>

int main(int argc, char *argv[])

{

    QApplication a(argc, argv);

    event_dlg w;

    try

    {

        w.set_config_file("./events.xml");

        w.show();

    }

    catch ( std::runtime_error & e )

    {

//        QMessageBox msgBox;

//        msgBox.setText(e.what());

//        msgBox.exec();

//        qDebug() << w.close();


        a.quit();

    }

        return a.exec();

}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20130726/17d7f026/attachment.html>


More information about the Interest mailing list