I have the following call in worker thread to invoke function call A in main thread. I notice QMetaMethod::invoke() calls QMetaType::construct(), and this function will call class B constructor. And later once it’s done, destructor is called in main thread. Why is it even input parameter is reference?
QMetaObject::invokeMethod(this, "A", Qt::QueuedConnection,
Q_ARG(const B &, b));
↧