[Qt-interest] signal emitted eveytime the dialog closes, in QT internally
Mandeep Sandhu
mandeepsandhu.chd at gmail.com
Tue Jun 28 16:08:53 CEST 2011
2011/6/28 Sahana Bhaskar <Sahana_Bhaskar at infosys.com>
> *≫** **how did you connect the slot, did connect return true etc. And how
> are you verifying that this slot is not called? Have you put debugs there?
> *
>
> *>**Yes I put a break on that statement .** I don’t understand how do I
> connect to the slot?*
>
By calling QObject::connect().
Without connect a signal to a slot (see docs on how to use connect), the
slot won't be called! :)
>
> *In the examples s**hown below I just added the below two functions to the
> same class. Now the control flows to changeevent on every event but not to
> **finished** on close. Why? *
>
changeEvent() gets called because its a virtual function in QFileDialog and
you're overloading it in your class (which i presume, you're extending from
QFileDialog).
Before you go any deeper, I suggest you read up some tutorials on how to use
signals/slots in Qt.
You can start here:
http://doc.qt.nokia.com/4.7/signalsandslots.html
HTH,
-mandeep
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20110628/29f31760/attachment.html
More information about the Qt-interest-old
mailing list