Take a look at : enum Qt::ConnectionType
Basically, when you connect a signal to a slot, you do something like :
connect(sender, SIGNAL(destroyed()), this, SLOT(objectDestroyed()));
connect(sender, SIGNAL(destroyed()), this, SLOT(objectDestroyed()));
To copy to clipboard, switch view to plain text mode
But, there is one more parameter the connection type.
If you look at the QObject::connect documentation, you will see that you are looking for this 5th argument : Qt::DirectConnection (documentation extract : The slot is invoked immediately, when the signal is emitted.)
Basically, just type
connect(sender, SIGNAL(destroyed()), this, SLOT(objectDestroyed()), Qt::DirectConnection);
connect(sender, SIGNAL(destroyed()), this, SLOT(objectDestroyed()), Qt::DirectConnection);
To copy to clipboard, switch view to plain text mode
Bookmarks