From 97c876a1353f29ed0129360f013f2529bed69d98 Mon Sep 17 00:00:00 2001 From: Milian Wolff Date: Wed, 25 May 2016 16:42:01 +0200 Subject: Enable calling C++ functions taking QJson arguments via webchannel. We used to convert the QJsonValue arguments to QVariants, which then failed to call a C++ function which expected on of the three QJson data types, i.e. QJsonValue, QJsonObject or QJsonArray. Instead, we now detect these three cases and manually convert the QJsonValue as needed. [ChangeLog] C++ functions taking arguments of type QJsonValue, QJsonArray or QJsonObject can now be called via the Qt WebChannel. Change-Id: I94e0c8937ca35e2ecd3554f7ddf2d4e5a3328570 Task-number: QTBUG-48198 Reviewed-by: Simon Hausmann --- tests/auto/webchannel/tst_webchannel.cpp | 41 ++++++++++++++++++++++++++++++++ tests/auto/webchannel/tst_webchannel.h | 5 ++++ 2 files changed, 46 insertions(+) (limited to 'tests') diff --git a/tests/auto/webchannel/tst_webchannel.cpp b/tests/auto/webchannel/tst_webchannel.cpp index f1911e5..4db8bae 100644 --- a/tests/auto/webchannel/tst_webchannel.cpp +++ b/tests/auto/webchannel/tst_webchannel.cpp @@ -216,6 +216,21 @@ void TestWebChannel::setVariant(const QVariant &v) m_lastVariant = v; } +void TestWebChannel::setJsonValue(const QJsonValue& v) +{ + m_lastJsonValue = v; +} + +void TestWebChannel::setJsonObject(const QJsonObject& v) +{ + m_lastJsonValue = v; +} + +void TestWebChannel::setJsonArray(const QJsonArray& v) +{ + m_lastJsonValue = v; +} + void TestWebChannel::testRegisterObjects() { QWebChannel channel; @@ -426,6 +441,32 @@ void TestWebChannel::testInvokeMethodConversion() channel.d_func()->publisher->invokeMethod(this, method, args); QCOMPARE(m_lastVariant, args.at(0).toVariant()); } + { + int method = metaObject()->indexOfMethod("setJsonValue(QJsonValue)"); + QVERIFY(method != -1); + channel.d_func()->publisher->invokeMethod(this, method, args); + QCOMPARE(m_lastJsonValue, args.at(0)); + } + { + int method = metaObject()->indexOfMethod("setJsonObject(QJsonObject)"); + QVERIFY(method != -1); + QJsonObject object; + object["foo"] = QJsonValue(123); + object["bar"] = QJsonValue(4.2); + args[0] = object; + channel.d_func()->publisher->invokeMethod(this, method, args); + QCOMPARE(m_lastJsonValue.toObject(), object); + } + { + int method = metaObject()->indexOfMethod("setJsonArray(QJsonArray)"); + QVERIFY(method != -1); + QJsonArray array; + array << QJsonValue(123); + array << QJsonValue(4.2); + args[0] = array; + channel.d_func()->publisher->invokeMethod(this, method, args); + QCOMPARE(m_lastJsonValue.toArray(), array); + } } void TestWebChannel::testDisconnect() diff --git a/tests/auto/webchannel/tst_webchannel.h b/tests/auto/webchannel/tst_webchannel.h index b2a1040..e551458 100644 --- a/tests/auto/webchannel/tst_webchannel.h +++ b/tests/auto/webchannel/tst_webchannel.h @@ -36,6 +36,7 @@ #include #include +#include #include @@ -229,6 +230,9 @@ public: Q_INVOKABLE void setInt(int i); Q_INVOKABLE void setDouble(double d); Q_INVOKABLE void setVariant(const QVariant &v); + Q_INVOKABLE void setJsonValue(const QJsonValue &v); + Q_INVOKABLE void setJsonObject(const QJsonObject &v); + Q_INVOKABLE void setJsonArray(const QJsonArray &v); private slots: void testRegisterObjects(); @@ -252,6 +256,7 @@ private: int m_lastInt; double m_lastDouble; QVariant m_lastVariant; + QJsonValue m_lastJsonValue; }; QT_END_NAMESPACE -- cgit v1.2.1 From bec50124b893c4632829d9806f49f64c4debf936 Mon Sep 17 00:00:00 2001 From: Milian Wolff Date: Wed, 25 May 2016 18:20:30 +0200 Subject: Fix setting properties of QJson{Value,Array,Object} type. Similar to the previous issue, where these types were not properly converted to QVariant when invoking a method, we manually do the conversion now to get the desired behavior. The culprit is again that QJsonValue::toVariant converts an object e.g. to a QVariantMap, and not to a QVariant containing a QJsonObject. [ChangeLog] QObject properties of type QJsonValue, QJsonArray or QJsonObject can now be set via the Qt WebChannel. Task-number: QTBUG-48198 Change-Id: I5d574b1a5cffd6d6ad9b555f2a3e872b9c3425a7 Reviewed-by: Simon Hausmann --- tests/auto/webchannel/tst_webchannel.cpp | 94 ++++++++++++++++++++++++++++++-- tests/auto/webchannel/tst_webchannel.h | 25 +++++++++ 2 files changed, 115 insertions(+), 4 deletions(-) (limited to 'tests') diff --git a/tests/auto/webchannel/tst_webchannel.cpp b/tests/auto/webchannel/tst_webchannel.cpp index 4db8bae..93c7aa8 100644 --- a/tests/auto/webchannel/tst_webchannel.cpp +++ b/tests/auto/webchannel/tst_webchannel.cpp @@ -200,35 +200,70 @@ TestWebChannel::~TestWebChannel() { } +int TestWebChannel::readInt() const +{ + return m_lastInt; +} void TestWebChannel::setInt(int i) { m_lastInt = i; + emit lastIntChanged(); +} + +double TestWebChannel::readDouble() const +{ + return m_lastDouble; } void TestWebChannel::setDouble(double d) { m_lastDouble = d; + emit lastDoubleChanged(); +} + +QVariant TestWebChannel::readVariant() const +{ + return m_lastVariant; } void TestWebChannel::setVariant(const QVariant &v) { m_lastVariant = v; + emit lastVariantChanged(); +} + +QJsonValue TestWebChannel::readJsonValue() const +{ + return m_lastJsonValue; } void TestWebChannel::setJsonValue(const QJsonValue& v) { m_lastJsonValue = v; + emit lastJsonValueChanged(); +} + +QJsonObject TestWebChannel::readJsonObject() const +{ + return m_lastJsonObject; } void TestWebChannel::setJsonObject(const QJsonObject& v) { - m_lastJsonValue = v; + m_lastJsonObject = v; + emit lastJsonObjectChanged(); +} + +QJsonArray TestWebChannel::readJsonArray() const +{ + return m_lastJsonArray; } void TestWebChannel::setJsonArray(const QJsonArray& v) { - m_lastJsonValue = v; + m_lastJsonArray = v; + emit lastJsonArrayChanged(); } void TestWebChannel::testRegisterObjects() @@ -455,7 +490,7 @@ void TestWebChannel::testInvokeMethodConversion() object["bar"] = QJsonValue(4.2); args[0] = object; channel.d_func()->publisher->invokeMethod(this, method, args); - QCOMPARE(m_lastJsonValue.toObject(), object); + QCOMPARE(m_lastJsonObject, object); } { int method = metaObject()->indexOfMethod("setJsonArray(QJsonArray)"); @@ -465,7 +500,58 @@ void TestWebChannel::testInvokeMethodConversion() array << QJsonValue(4.2); args[0] = array; channel.d_func()->publisher->invokeMethod(this, method, args); - QCOMPARE(m_lastJsonValue.toArray(), array); + QCOMPARE(m_lastJsonArray, array); + } +} + +void TestWebChannel::testSetPropertyConversion() +{ + QWebChannel channel; + channel.connectTo(m_dummyTransport); + + { + int property = metaObject()->indexOfProperty("lastInt"); + QVERIFY(property != -1); + channel.d_func()->publisher->setProperty(this, property, QJsonValue(42)); + QCOMPARE(m_lastInt, 42); + } + { + int property = metaObject()->indexOfProperty("lastDouble"); + QVERIFY(property != -1); + channel.d_func()->publisher->setProperty(this, property, QJsonValue(-4.2)); + QCOMPARE(m_lastDouble, -4.2); + } + { + int property = metaObject()->indexOfProperty("lastVariant"); + QVERIFY(property != -1); + QVariant variant("foo bar asdf"); + channel.d_func()->publisher->setProperty(this, property, QJsonValue::fromVariant(variant)); + QCOMPARE(m_lastVariant, variant); + } + { + int property = metaObject()->indexOfProperty("lastJsonValue"); + QVERIFY(property != -1); + QJsonValue value("asdf asdf"); + channel.d_func()->publisher->setProperty(this, property, value); + QCOMPARE(m_lastJsonValue, value); + } + { + int property = metaObject()->indexOfProperty("lastJsonArray"); + QVERIFY(property != -1); + QJsonArray array; + array << QJsonValue(-123); + array << QJsonValue(-42); + channel.d_func()->publisher->setProperty(this, property, array); + QCOMPARE(m_lastJsonArray, array); + } + { + int property = metaObject()->indexOfProperty("lastJsonObject"); + QVERIFY(property != -1); + QJsonObject object; + object["foo"] = QJsonValue(-123); + object["bar"] = QJsonValue(-4.2); + channel.d_func()->publisher->setProperty(this, property, object); + QCOMPARE(m_lastJsonObject, object); } } diff --git a/tests/auto/webchannel/tst_webchannel.h b/tests/auto/webchannel/tst_webchannel.h index e551458..13294c2 100644 --- a/tests/auto/webchannel/tst_webchannel.h +++ b/tests/auto/webchannel/tst_webchannel.h @@ -37,6 +37,8 @@ #include #include #include +#include +#include #include @@ -223,22 +225,43 @@ class TestWebChannel : public QObject { Q_OBJECT + Q_PROPERTY(int lastInt READ readInt WRITE setInt NOTIFY lastIntChanged); + Q_PROPERTY(double lastDouble READ readDouble WRITE setDouble NOTIFY lastDoubleChanged); + Q_PROPERTY(QVariant lastVariant READ readVariant WRITE setVariant NOTIFY lastVariantChanged); + Q_PROPERTY(QJsonValue lastJsonValue READ readJsonValue WRITE setJsonValue NOTIFY lastJsonValueChanged); + Q_PROPERTY(QJsonObject lastJsonObject READ readJsonObject WRITE setJsonObject NOTIFY lastJsonObjectChanged); + Q_PROPERTY(QJsonArray lastJsonArray READ readJsonArray WRITE setJsonArray NOTIFY lastJsonArrayChanged); public: explicit TestWebChannel(QObject *parent = 0); virtual ~TestWebChannel(); + int readInt() const; Q_INVOKABLE void setInt(int i); + double readDouble() const; Q_INVOKABLE void setDouble(double d); + QVariant readVariant() const; Q_INVOKABLE void setVariant(const QVariant &v); + QJsonValue readJsonValue() const; Q_INVOKABLE void setJsonValue(const QJsonValue &v); + QJsonObject readJsonObject() const; Q_INVOKABLE void setJsonObject(const QJsonObject &v); + QJsonArray readJsonArray() const; Q_INVOKABLE void setJsonArray(const QJsonArray &v); +signals: + void lastIntChanged(); + void lastDoubleChanged(); + void lastVariantChanged(); + void lastJsonValueChanged(); + void lastJsonObjectChanged(); + void lastJsonArrayChanged(); + private slots: void testRegisterObjects(); void testDeregisterObjects(); void testInfoForObject(); void testInvokeMethodConversion(); + void testSetPropertyConversion(); void testDisconnect(); void testWrapRegisteredObject(); void testInfiniteRecursion(); @@ -257,6 +280,8 @@ private: double m_lastDouble; QVariant m_lastVariant; QJsonValue m_lastJsonValue; + QJsonObject m_lastJsonObject; + QJsonArray m_lastJsonArray; }; QT_END_NAMESPACE -- cgit v1.2.1 From f48e8c9711fbeb350ccf70f852ce3732844d4287 Mon Sep 17 00:00:00 2001 From: Kai Dohmen Date: Mon, 11 Apr 2016 19:38:50 +0200 Subject: Make passing objects from website to server possible If you get an object from the server and want to pass it back to the server via a function the id of the object is passed instead of the whole json object. On the server side QMetaObjectPublisher::invokeMethod now looks up the object in QMetaObjectPublisher::wrappedObjects by the passed object-id. Task-number: QTBUG-50075 Change-Id: Id0df2dfaa79bcba12ca48391ae7537ac1a086898 Reviewed-by: Milian Wolff --- tests/auto/webchannel/tst_webchannel.cpp | 50 ++++++++++++++++++++++++++++++++ tests/auto/webchannel/tst_webchannel.h | 16 ++++++++++ 2 files changed, 66 insertions(+) (limited to 'tests') diff --git a/tests/auto/webchannel/tst_webchannel.cpp b/tests/auto/webchannel/tst_webchannel.cpp index 93c7aa8..7ae6f78 100644 --- a/tests/auto/webchannel/tst_webchannel.cpp +++ b/tests/auto/webchannel/tst_webchannel.cpp @@ -343,6 +343,12 @@ void TestWebChannel::testInfoForObject() method.append(obj.metaObject()->indexOfMethod("slot2(QString)")); expected.append(method); } + { + QJsonArray method; + method.append(QStringLiteral("setReturnedObject")); + method.append(obj.metaObject()->indexOfMethod("setReturnedObject(TestObject*)")); + expected.append(method); + } { QJsonArray method; method.append(QStringLiteral("setObjectProperty")); @@ -446,6 +452,19 @@ void TestWebChannel::testInfoForObject() property.append(QJsonValue::fromVariant(QVariant::fromValue(obj.objectProperty()))); expected.append(property); } + { + QJsonArray property; + property.append(obj.metaObject()->indexOfProperty("returnedObject")); + property.append(QStringLiteral("returnedObject")); + { + QJsonArray signal; + signal.append(1); + signal.append(obj.metaObject()->indexOfMethod("returnedObjectChanged()")); + property.append(signal); + } + property.append(QJsonValue::fromVariant(QVariant::fromValue(obj.returnedObject()))); + expected.append(property); + } QCOMPARE(info["properties"].toArray(), expected); } } @@ -587,6 +606,36 @@ void TestWebChannel::testWrapRegisteredObject() QCOMPARE(obj.objectName(), returnedId); } +void TestWebChannel::testPassWrappedObjectBack() +{ + QWebChannel channel; + TestObject registeredObj; + TestObject returnedObjMethod; + TestObject returnedObjProperty; + + registeredObj.setObjectName("registeredObject"); + + channel.registerObject(registeredObj.objectName(), ®isteredObj); + channel.connectTo(m_dummyTransport); + channel.d_func()->publisher->initializeClient(m_dummyTransport); + + QMetaObjectPublisher *pub = channel.d_func()->publisher; + QJsonObject returnedObjMethodInfo = pub->wrapResult(QVariant::fromValue(&returnedObjMethod), m_dummyTransport).toObject(); + QJsonObject returnedObjPropertyInfo = pub->wrapResult(QVariant::fromValue(&returnedObjProperty), m_dummyTransport).toObject(); + + QJsonArray argsMethod; + QJsonObject argMethod0; + argMethod0["id"] = returnedObjMethodInfo["id"]; + argsMethod << argMethod0; + QJsonObject argProperty; + argProperty["id"] = returnedObjPropertyInfo["id"]; + + pub->invokeMethod(®isteredObj, registeredObj.metaObject()->indexOfSlot("setReturnedObject(TestObject*)"), argsMethod); + QCOMPARE(registeredObj.mReturnedObject, &returnedObjMethod); + pub->setProperty(®isteredObj, registeredObj.metaObject()->indexOfProperty("returnedObject"), argProperty); + QCOMPARE(registeredObj.mReturnedObject, &returnedObjProperty); +} + void TestWebChannel::testInfiniteRecursion() { QWebChannel channel; @@ -739,6 +788,7 @@ void TestWebChannel::qtbug46548_overriddenProperties() #endif // WEBCHANNEL_TESTS_CAN_USE_JS_ENGINE } + QTEST_MAIN(TestWebChannel) #include "tst_webchannel.moc" diff --git a/tests/auto/webchannel/tst_webchannel.h b/tests/auto/webchannel/tst_webchannel.h index 13294c2..5a9fa11 100644 --- a/tests/auto/webchannel/tst_webchannel.h +++ b/tests/auto/webchannel/tst_webchannel.h @@ -73,11 +73,13 @@ class TestObject : public QObject Q_PROPERTY(int asdf READ asdf NOTIFY asdfChanged) Q_PROPERTY(QString bar READ bar NOTIFY theBarHasChanged) Q_PROPERTY(QObject * objectProperty READ objectProperty WRITE setObjectProperty NOTIFY objectPropertyChanged) + Q_PROPERTY(TestObject * returnedObject READ returnedObject WRITE setReturnedObject NOTIFY returnedObjectChanged) public: explicit TestObject(QObject *parent = 0) : QObject(parent) , mObjectProperty(0) + , mReturnedObject(Q_NULLPTR) { } enum Foo { @@ -94,6 +96,11 @@ public: return mObjectProperty; } + TestObject *returnedObject() const + { + return mReturnedObject; + } + Q_INVOKABLE void method1() {} protected: @@ -108,11 +115,18 @@ signals: void asdfChanged(); void theBarHasChanged(); void objectPropertyChanged(); + void returnedObjectChanged(); public slots: void slot1() {} void slot2(const QString&) {} + void setReturnedObject(TestObject *obj) + { + mReturnedObject = obj; + emit returnedObjectChanged(); + } + void setObjectProperty(QObject *object) { mObjectProperty = object; @@ -127,6 +141,7 @@ private slots: public: QObject *mObjectProperty; + TestObject *mReturnedObject; }; class BenchObject : public QObject @@ -264,6 +279,7 @@ private slots: void testSetPropertyConversion(); void testDisconnect(); void testWrapRegisteredObject(); + void testPassWrappedObjectBack(); void testInfiniteRecursion(); void benchClassInfo(); -- cgit v1.2.1 From d3c594c382761241742cd6713f249abeb538ffaa Mon Sep 17 00:00:00 2001 From: Milian Wolff Date: Tue, 21 Jun 2016 11:30:03 +0200 Subject: Properly unwrap QObject signal parameters on the JavaScript side. This enables you to pass `QObject*` parameters via signals to the JavaScript side. The object will be serialized and then unwrapped as needed now. Task-number: QTBUG-54243 Change-Id: Ie8a6d14eb1351f14f1855d242ceb3b3f8262152d Reviewed-by: Andreas Holzammer --- tests/auto/qml/tst_webchannel.qml | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) (limited to 'tests') diff --git a/tests/auto/qml/tst_webchannel.qml b/tests/auto/qml/tst_webchannel.qml index f1042ca..6cb24b0 100644 --- a/tests/auto/qml/tst_webchannel.qml +++ b/tests/auto/qml/tst_webchannel.qml @@ -51,7 +51,7 @@ TestCase { id: myObj property int myProperty: 1 - signal mySignal(var arg) + signal mySignal(var arg, QtObject object) function myMethod(arg) { @@ -174,9 +174,11 @@ TestCase { function test_signal() { var signalReceivedArg; + var signalReceivedObject; var channel = client.createChannel(function(channel) { - channel.objects.myObj.mySignal.connect(function(arg) { + channel.objects.myObj.mySignal.connect(function(arg, object) { signalReceivedArg = arg; + signalReceivedObject = object; }); }); client.awaitInit(); @@ -187,9 +189,16 @@ TestCase { client.awaitIdle(); // initialization - myObj.mySignal("test"); + myObj.mySignal("test", myObj); compare(signalReceivedArg, "test"); + compare(signalReceivedObject.__id__, "myObj"); + + var newObj = myFactory.create("newObj"); + myObj.mySignal(newObj, newObj); + + compare(signalReceivedArg.objectName, newObj.objectName); + compare(signalReceivedObject.objectName, newObj.objectName); } function test_grouping() @@ -393,14 +402,14 @@ TestCase { client.awaitIdle(); - myObj.mySignal(42); + myObj.mySignal(42, myObj); compare(signalArg, 42); msg = client.awaitMessage(); compare(msg.type, JSClient.QWebChannelMessageTypes.disconnectFromSignal); compare(msg.object, "myObj"); - myObj.mySignal(0); + myObj.mySignal(0, myObj); compare(signalArg, 42); } } -- cgit v1.2.1 From e35346cf70598c47a456946327927643910aa277 Mon Sep 17 00:00:00 2001 From: Milian Wolff Date: Thu, 16 Jun 2016 12:46:42 +0200 Subject: Add test to verify that bools get properly converted. This test passes and seems to indicate that the signal-delivery has an issue, or that the issue lies on the JavaScript side. Change-Id: Ic2436147b3af49d35dc556da57aed3e54408f1f9 Task-number: QTBUG-54074 Reviewed-by: Frederik Gladhorn --- tests/auto/webchannel/tst_webchannel.cpp | 28 ++++++++++++++++++++++++++++ tests/auto/webchannel/tst_webchannel.h | 5 +++++ 2 files changed, 33 insertions(+) (limited to 'tests') diff --git a/tests/auto/webchannel/tst_webchannel.cpp b/tests/auto/webchannel/tst_webchannel.cpp index 7ae6f78..71779b9 100644 --- a/tests/auto/webchannel/tst_webchannel.cpp +++ b/tests/auto/webchannel/tst_webchannel.cpp @@ -192,6 +192,7 @@ TestWebChannel::TestWebChannel(QObject *parent) : QObject(parent) , m_dummyTransport(new DummyTransport(this)) , m_lastInt(0) + , m_lastBool(false) , m_lastDouble(0) { } @@ -200,6 +201,7 @@ TestWebChannel::~TestWebChannel() { } + int TestWebChannel::readInt() const { return m_lastInt; @@ -211,6 +213,17 @@ void TestWebChannel::setInt(int i) emit lastIntChanged(); } +bool TestWebChannel::readBool() const +{ + return m_lastBool; +} + +void TestWebChannel::setBool(bool b) +{ + m_lastBool = b; + emit lastBoolChanged(); +} + double TestWebChannel::readDouble() const { return m_lastDouble; @@ -483,6 +496,14 @@ void TestWebChannel::testInvokeMethodConversion() channel.d_func()->publisher->invokeMethod(this, method, args); QCOMPARE(m_lastInt, args.at(0).toInt()); } + { + int method = metaObject()->indexOfMethod("setBool(bool)"); + QVERIFY(method != -1); + QJsonArray args; + args.append(QJsonValue(!m_lastBool)); + channel.d_func()->publisher->invokeMethod(this, method, args); + QCOMPARE(m_lastBool, args.at(0).toBool()); + } { int method = metaObject()->indexOfMethod("setDouble(double)"); QVERIFY(method != -1); @@ -534,6 +555,13 @@ void TestWebChannel::testSetPropertyConversion() channel.d_func()->publisher->setProperty(this, property, QJsonValue(42)); QCOMPARE(m_lastInt, 42); } + { + int property = metaObject()->indexOfProperty("lastBool"); + QVERIFY(property != -1); + bool newValue = !m_lastBool; + channel.d_func()->publisher->setProperty(this, property, QJsonValue(newValue)); + QCOMPARE(m_lastBool, newValue); + } { int property = metaObject()->indexOfProperty("lastDouble"); QVERIFY(property != -1); diff --git a/tests/auto/webchannel/tst_webchannel.h b/tests/auto/webchannel/tst_webchannel.h index 5a9fa11..3469d41 100644 --- a/tests/auto/webchannel/tst_webchannel.h +++ b/tests/auto/webchannel/tst_webchannel.h @@ -241,6 +241,7 @@ class TestWebChannel : public QObject Q_OBJECT Q_PROPERTY(int lastInt READ readInt WRITE setInt NOTIFY lastIntChanged); + Q_PROPERTY(bool lastBool READ readBool WRITE setBool NOTIFY lastBoolChanged); Q_PROPERTY(double lastDouble READ readDouble WRITE setDouble NOTIFY lastDoubleChanged); Q_PROPERTY(QVariant lastVariant READ readVariant WRITE setVariant NOTIFY lastVariantChanged); Q_PROPERTY(QJsonValue lastJsonValue READ readJsonValue WRITE setJsonValue NOTIFY lastJsonValueChanged); @@ -252,6 +253,8 @@ public: int readInt() const; Q_INVOKABLE void setInt(int i); + bool readBool() const; + Q_INVOKABLE void setBool(bool b); double readDouble() const; Q_INVOKABLE void setDouble(double d); QVariant readVariant() const; @@ -265,6 +268,7 @@ public: signals: void lastIntChanged(); + void lastBoolChanged(); void lastDoubleChanged(); void lastVariantChanged(); void lastJsonValueChanged(); @@ -293,6 +297,7 @@ private: DummyTransport *m_dummyTransport; int m_lastInt; + bool m_lastBool; double m_lastDouble; QVariant m_lastVariant; QJsonValue m_lastJsonValue; -- cgit v1.2.1