[Qt-interest] Qt 4.5 Signals Slots on Mingw problem

Jesús Fernández jsfdez at gmail.com
Thu Mar 12 13:48:05 CET 2009


You are connecting the SIGNAL to the SLOT "correctly" but, you are also
using the autoconnect of QObjects:

http://doc.trolltech.com/4.4/designer-using-a-component.html#widgets-and-dialogs-with-auto-connect

On Thu, Mar 12, 2009 at 1:41 PM, Nikos Geronitidis <geronik444 at gmail.com>wrote:

> some sample code is here :
>
> *Ui::MyForm ui;
> //
> connect(ui.action_myaction, SIGNAL(triggered()), this, SLOT(on_**
> action_myaction_triggered()**));*
> //
> I am posting only this sample of code ,because I realized that when I
> change the name of my slot function to :
> e.g. *
> //
> on_action_myaction_just_triggered()*
> //
> *connect(ui.action_myaction, SIGNAL(triggered()), this, SLOT(on_**
> action_myaction_just_triggered()**));*
> //
> no problem exists and the slot is being received only once.
> Could the name of a slot in conjuction with the signals name cause any
> problem in this case?
>
>
> ---------- Forwarded message ----------
> From: Jesús Fernández <jsfdez at gmail.com>
> Date: Thu, Mar 12, 2009 at 2:16 PM
> Subject: Re: [Qt-interest] Qt 4.5 Signals Slots on Mingw problem
> To:
> Cc: qt-interest at trolltech.com
>
>
> Show the code, please.
>
> On Thu, Mar 12, 2009 at 12:59 PM, Nikos Geronitidis <geronik444 at gmail.com>wrote:
>
>> Hello list
>>
>> I have a *QAction triggered() signal* connected to a *slot* on my *QMainWindow
>> *application, which is called twice every time.
>> I have built my application with Qt 4.5 and mingw.
>> Any ideas why this is happening?
>>
>> --
>> Best Regards
>> Nikos Gerontidis
>>
>> _______________________________________________
>> Qt-interest mailing list
>> Qt-interest at trolltech.com
>> http://lists.trolltech.com/mailman/listinfo/qt-interest
>>
>>
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
>
>
>
>
> --
> Best Regards
> Nikos Gerontidis
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090312/41a2697a/attachment.html 


More information about the Qt-interest-old mailing list