Doubt about signal and slots in QT

1

Hi, I'm starting to program QT in order to learn as much as possible but I have a question. I know that with a signal you can connect them to many slots. (Example multiple actions or move different progress bars). But what is not is when one of those slots is busy what happens with the rest of the slots? And if for example I have mistakenly made an infinite loop and the signal never ends what happens with the other signals? Because I am a beginner and I want to learn the maximum possible theory. Forgive if you explained me wrong.

    
asked by Perl 05.10.2016 в 19:51
source

1 answer

1

Qt is multi-threaded, however, by default, the execution of a signal is to be executed in a single thread (this is how the execution loop is programmed). This implies that the different slots will be executed sequentially.

Because of this, if the execution is stuck in a slot by an infinite loop, an active wait, a costly task, etc. Subsequent slots will not be executed, or at least not until the execution leaves the problematic slot.

Greetings

    
answered by 05.10.2016 / 20:45
source