Updated mainwindow.cpp to show the form with:
purge dialog(this);
dialog.exec()
purge dialog(this);
dialog.exec()
To copy to clipboard, switch view to plain text mode
Updated purge.h to:
protected:
protected:
void changeEvent(QEvent *e);
void showEvent(QShowEvent *);
void closeEvent(QCloseEvent *e);
To copy to clipboard, switch view to plain text mode
Updated purge.cpp to make a call to purgeCache function in the showEvent:
{
qDebug() << "in the show event";
purge::purgeCache();
}
void purge::showEvent(QShowEvent *)
{
qDebug() << "in the show event";
purge::purgeCache();
}
To copy to clipboard, switch view to plain text mode
Updated purge.cpp to output when the closeEvent occurs:
{
qDebug() << " in the close event";
}
void purge::closeEvent(QCloseEvent *e)
{
qDebug() << " in the close event";
}
To copy to clipboard, switch view to plain text mode
I can clearly see the call to close the window, yet it does not close.
Also, now that I am calling the purgeCache function from the showEvent, and the purgeCache function includes "close()" the form will not close whatsoever. Every time I click the close button on the window manager, it outputs "in the close event", so I show to be in the close handler, yet it doesn't happen, and I have to kill the app.
Once again, I apprecaite your input
Bookmarks