summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTarja Sundqvist <tarja.sundqvist@qt.io>2022-08-16 20:37:46 +0300
committerTarja Sundqvist <tarja.sundqvist@qt.io>2022-08-16 20:37:46 +0300
commitaa705010da0f658b78c1155babce7091ae44529a (patch)
treefd2ee3e35baea34d79de710380be3f2a8dba7ed8
parent89407ff20e4f76314887e2f3625f5126910031ac (diff)
parent96a5cabe4db859c347788c764e61191927523b4b (diff)
Merge remote-tracking branch 'origin/tqtc/lts-5.15.6' into tqtc/lts-5.15-opensourcev5.15.6-lts-lgpl
-rw-r--r--.qmake.conf2
-rw-r--r--src/remoteobjects/Qt5RemoteObjectsMacros.cmake3
-rw-r--r--src/remoteobjects/qremoteobjectdynamicreplica.cpp8
-rw-r--r--src/remoteobjects/qremoteobjectpacket.cpp11
-rw-r--r--src/remoteobjects/qremoteobjectreplica.cpp13
5 files changed, 18 insertions, 19 deletions
diff --git a/.qmake.conf b/.qmake.conf
index 1c1f34c..df72b25 100644
--- a/.qmake.conf
+++ b/.qmake.conf
@@ -4,6 +4,6 @@ CONFIG += qt_example_installs
DEFINES += QT_NO_JAVA_STYLE_ITERATORS
DEFINES += QT_NO_FOREACH
-MODULE_VERSION = 5.15.5
+MODULE_VERSION = 5.15.6
QTRO_SOURCE_TREE = $$PWD
diff --git a/src/remoteobjects/Qt5RemoteObjectsMacros.cmake b/src/remoteobjects/Qt5RemoteObjectsMacros.cmake
index 4c65037..c5ee12e 100644
--- a/src/remoteobjects/Qt5RemoteObjectsMacros.cmake
+++ b/src/remoteobjects/Qt5RemoteObjectsMacros.cmake
@@ -105,7 +105,8 @@ if(NOT QT_NO_CREATE_VERSIONLESS_FUNCTIONS)
if(QT_DEFAULT_MAJOR_VERSION EQUAL 5)
qt5_generate_repc("${outfiles}" ${ARGN})
elseif(QT_DEFAULT_MAJOR_VERSION EQUAL 6)
- qt6_generate_repc("${outfiles}" ${ARGN})
+ message(FATAL_ERROR "qt_generate_repc is not available in Qt6. "
+ "See the Qt6 documentation for replacements.")
endif()
set("${outfiles}" "${${outfiles}}" PARENT_SCOPE)
endfunction()
diff --git a/src/remoteobjects/qremoteobjectdynamicreplica.cpp b/src/remoteobjects/qremoteobjectdynamicreplica.cpp
index a004593..616c3ca 100644
--- a/src/remoteobjects/qremoteobjectdynamicreplica.cpp
+++ b/src/remoteobjects/qremoteobjectdynamicreplica.cpp
@@ -142,7 +142,6 @@ int QRemoteObjectDynamicReplica::qt_metacall(QMetaObject::Call call, int id, voi
if (call == QMetaObject::ReadProperty || call == QMetaObject::WriteProperty) {
QMetaProperty mp = metaObject()->property(saved_id);
- int &status = *reinterpret_cast<int *>(argv[2]);
if (call == QMetaObject::WriteProperty) {
QVariantList args;
@@ -159,13 +158,6 @@ int QRemoteObjectDynamicReplica::qt_metacall(QMetaObject::Call call, int id, voi
QMetaType::destruct(mp.userType(), argv[0]);
QMetaType::construct(mp.userType(), argv[0], value.data());
}
- const bool readStatus = true;
- // Caller supports QVariant returns? Then we can also report errors
- // by storing an invalid variant.
- if (!readStatus && argv[1]) {
- status = 0;
- reinterpret_cast<QVariant*>(argv[1])->clear();
- }
}
id = -1;
diff --git a/src/remoteobjects/qremoteobjectpacket.cpp b/src/remoteobjects/qremoteobjectpacket.cpp
index d517794..b5be767 100644
--- a/src/remoteobjects/qremoteobjectpacket.cpp
+++ b/src/remoteobjects/qremoteobjectpacket.cpp
@@ -480,13 +480,10 @@ void serializeDefinition(QDataStream &ds, const QRemoteObjectSourceBase *source)
serializeEnum(ds, enumerator);
}
- if (source->d->isDynamic) {
- QSet<const QMetaObject *> gadgets;
- QSet<QMetaEnum> enums;
- recurseForGadgets(gadgets, enums, source);
- serializeGadgets(ds, gadgets, enums, source);
- } else
- ds << quint32(0) << quint32(0); // qtEnums, numGadgets
+ QSet<const QMetaObject *> gadgets;
+ QSet<QMetaEnum> enums;
+ recurseForGadgets(gadgets, enums, source);
+ serializeGadgets(ds, gadgets, enums, source);
const int numSignals = api->signalCount();
ds << quint32(numSignals); //Number of signals
diff --git a/src/remoteobjects/qremoteobjectreplica.cpp b/src/remoteobjects/qremoteobjectreplica.cpp
index 6b2c6cf..ddfe3ec 100644
--- a/src/remoteobjects/qremoteobjectreplica.cpp
+++ b/src/remoteobjects/qremoteobjectreplica.cpp
@@ -345,8 +345,11 @@ bool QConnectedReplicaImplementation::waitForSource(int timeout)
&loop, QEventLoop::staticMetaObject.indexOfMethod("quit()"),
Qt::DirectConnection, nullptr);
+ QTimer t; // NB: Related to QTBUG-94570 - don't use QTimer::singleShot here.
if (timeout >= 0) {
- QTimer::singleShot(timeout, &loop, &QEventLoop::quit);
+ t.setSingleShot(true);
+ connect(&t, &QTimer::timeout, &loop, &QEventLoop::quit);
+ t.start(timeout);
}
// enter the event loop and wait for a reply
@@ -439,7 +442,13 @@ bool QConnectedReplicaImplementation::waitForFinished(const QRemoteObjectPending
QEventLoop loop;
loop.connect(call.d->watcherHelper.data(), &QRemoteObjectPendingCallWatcherHelper::finished,
&loop, &QEventLoop::quit);
- QTimer::singleShot(timeout, &loop, &QEventLoop::quit);
+
+ QTimer t; // NB: Related to QTBUG-94570 - don't use QTimer::singleShot here.
+ if (timeout >= 0) {
+ t.setSingleShot(true);
+ connect(&t, &QTimer::timeout, &loop, &QEventLoop::quit);
+ t.start(timeout);
+ }
// enter the event loop and wait for a reply
loop.exec(QEventLoop::ExcludeUserInputEvents | QEventLoop::WaitForMoreEvents);