QtObject created and returned by singleton, how to attached slots ?
-
I have a singleton that manages object creation in C++ I return an instance of the created object to a QML property. C++:
Q_INVOKABLE QObject* newInstance(const QString& crstrTag_) { return new staledata_t(crstrTag_); }In the QML:
instance = DataMngr.newInstance(instanceID)How can I assign QML slots to the singles that this instance C++ emits: C++ signals:
signals: void dataChanged(double dblData_); void interface(bool blnState_); void toolTip(QString strToolTip_); -
I have a singleton that manages object creation in C++ I return an instance of the created object to a QML property. C++:
Q_INVOKABLE QObject* newInstance(const QString& crstrTag_) { return new staledata_t(crstrTag_); }In the QML:
instance = DataMngr.newInstance(instanceID)How can I assign QML slots to the singles that this instance C++ emits: C++ signals:
signals: void dataChanged(double dblData_); void interface(bool blnState_); void toolTip(QString strToolTip_);