[Interest] Send Data to JavaScript
John Schneiderman
jschneiderman at gog.com
Mon Apr 12 15:17:13 CEST 2021
I'm attempting to send data to the JavaScript side of the QWebEngine
code. This data is being emitted via a signal. The registration is
connected correctly as other components work just fine, though they're
emitting only a single int or QString.
An example of what I'm attempting is below:
class Demo : QObject
{
Q_OBJECT
public:
Q_PROPERTY(
QMap<QString, QStringList> mappings
MEMBER mappings_
NOTIFY mappingsChanged
)
};
What I'm expecting is that mappings would be transformed on the
JavaScript side as:
mappings {
"key" : ["abc", "def"]...
}
However, when I try to view the data in the emitted signal it's always
null. Any suggestions where I should look for more answers or perhaps
I'm going in an incorrect direction?
Thanks,
--
John Schneiderman
Senior Software Engineer
CDPR Squad
GOG.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_0xB23C7A7C8E96CE3B.asc
Type: application/pgp-keys
Size: 2458 bytes
Desc: OpenPGP public key
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20210412/bcd343dc/attachment.key>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 665 bytes
Desc: OpenPGP digital signature
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20210412/bcd343dc/attachment.sig>
More information about the Interest
mailing list