Doubt regarding QT

E

edu.mvk

Can we use the slots in QCopchannel as ordinary member functions ??

that means in QT we have to connect the SLOTs to SIGNALS and that will
be invoked if the signal is happend

is it possible for me to call a slot from any other member function of
the same class just like ordinary member functions...??

Thanks.
 
M

mlimber

edu.mvk said:
Can we use the slots in QCopchannel as ordinary member functions ??

that means in QT we have to connect the SLOTs to SIGNALS and that will
be invoked if the signal is happend

is it possible for me to call a slot from any other member function of
the same class just like ordinary member functions...??

I have no idea about QT, and in fact, it is off-topic here. If you can
reformulate your question in terms of the standard C++ language (the
topic of this newsgroup), we would be happy to take a stab at it.
Otherwise, you'll want to ask in a more appropriate group. See this FAQ
for what is on-topic here and for a list of some other groups:

http://www.parashift.com/c++-faq-lite/how-to-post.html#faq-5.9

Cheers! --M
 
B

Bernd Strieder

Hello,

edu.mvk said:
Can we use the slots in QCopchannel as ordinary member functions ??

that means in QT we have to connect the SLOTs to SIGNALS and that will
be invoked if the signal is happend

is it possible for me to call a slot from any other member function of
the same class just like ordinary member functions...??

Yes you can. Qt just adds some stuff through its precompiler "moc", to
make the signal-slot-connections possible and to implement the signals
as ordinary member functions and leaves the slots as ordinary member
functions. Look at the generated code and at the user code after C
preprocessing. This should be valid C++ only.

Bernd Strieder
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,059
Latest member
cryptoseoagencies

Latest Threads

Top