PDA

View Full Version : Close child window notification in parent



doczorg
28th January 2010, 11:54
Hello all!
Still a newbee, so be patient please ;)
I'm trying to capture, in a parent window, when it's child window is closed. Like that, in the parent class, I know when the window is closed and I can do stuff.
How can that be done?
Thanks in advance
Regards
Neil.

boudie
28th January 2010, 18:30
In case of a modal dialog you use exec() to show the dialog. When it returns, you know it closed.
This is in most cases what you want.

In case of a modeless dialog, emit a signal to the parent, notfiying it is about to close.

And of course, you read this:
http://doc.qt.nokia.com/4.6/qdialog.html#details