P
P
pixik2015-10-01 16:04:02
Qt
pixik, 2015-10-01 16:04:02

QT signal, slot -- how to connect 2 objects that clearly "do not see" each other?

Good afternoon!
Stalknulsya with such task:
- there is an object A - mainWindow (GUI)
- there is an object B - a stream. its owner - object A
- is object C - another thread. Its owner is object B.
You need to link objects A and C through signals and slots. (roughly speaking, clicking on the button on the GUI - something "calls" in the object C).
While the obvious option is to forward signals and slots from A to C through B, but this is an overhead. To connect a new signal of object A to the slot of object C, 2 more functions are needed: a signal and a slot on object B.
Perhaps there are more rational solutions.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question