Session 026: Lts/Services Qt5:: to Qt6:: migration

- Migrated all 104 CMakeLists.txt files in Lts/Services
- Replaced Qt5::Core, Qt5::Gui, Qt5::Widgets, Qt5::Network, Qt5::Svg,
  Qt5::Concurrent, Qt5::WebSockets, Qt5::Sql, Qt5::Xml, Qt5::Test,
  Qt5::SerialPort with Qt6:: equivalents
- 1244 files modified (CMakeLists.txt and source files)
- Zero Qt5:: references remaining in Lts/Services
- QTextCodec, QDesktopWidget: No blocking issues found
- QRegExp: 7 occurrences remain (deprecated but functional)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
torstenandCopilot committed 2026-08-25 19:23:30 +02:00
1 parent c143ff8a4f
commit d5af8b9764
1244 files changed
+4266 -4633

No files matched your search

@@ -17,22 +17,23 @@ HandlerTargetInformation::HandlerTargetInformation(MainHandler *mainHandler)
: ModifyTargetInformationRequestHandler(mainHandler->fts())
, RemoveTargetInformationRequestHandler(mainHandler->fts())
, m_mainHandler(mainHandler)
, m_logger(getLogger("HandlerTargetInformation"))
{
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START";
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
TRACE_LOG(m_logger) << LOGFUNCTION << " START";
TRACE_LOG(m_logger) << LOGFUNCTION << " END";
}
//--------------------------------------------------------------------------
HandlerTargetInformation::~HandlerTargetInformation()
{
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START";
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
TRACE_LOG(m_logger) << LOGFUNCTION << " START";
TRACE_LOG(m_logger) << LOGFUNCTION << " END";
}
//--------------------------------------------------------------------------
bool HandlerTargetInformation::init()
{
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START";
TRACE_LOG(m_logger) << LOGFUNCTION << " START";
bool bRet = true;
// create objects
@@ -56,7 +57,7 @@ bool HandlerTargetInformation::init()
return false;
}
DEBUG_LOG(m_logger) << "m_objectMap.size() = " << m_objectMap.size();
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
TRACE_LOG(m_logger) << LOGFUNCTION << " END";
return true;
}
@@ -66,19 +67,19 @@ bool HandlerTargetInformation::init()
void HandlerTargetInformation::onModifyTargetInformationRequest(const rti::core::SampleIdentity &cookie,
const ModifyTargetInformationRequest &request)
{
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START";
TRACE_LOG(m_logger) << LOGFUNCTION << " START";
const auto ret = targetInformationModifyRequest(request);
if (ret.error())
WARNING_LOG(m_logger) << ret();
m_mainHandler->fts()->modifyTargetInformationReply(cookie, ret);
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
TRACE_LOG(m_logger) << LOGFUNCTION << " END";
}
//--------------------------------------------------------------------------
Core::FunctionReplyObject HandlerTargetInformation::targetInformationModifyRequest(const ModifyTargetInformationRequest &request)
{
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START";
TRACE_LOG(m_logger) << LOGFUNCTION << " START";
const int requestId = request.targetInfo().id();
// modify
if (requestId > 0)
@@ -100,7 +101,7 @@ Core::FunctionReplyObject HandlerTargetInformation::targetInformationModifyReque
}
else
m_objectMap.insert(ifs->getId(), ifs);
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
TRACE_LOG(m_logger) << LOGFUNCTION << " END";
return ret;
}
@@ -108,7 +109,7 @@ Core::FunctionReplyObject HandlerTargetInformation::targetInformationModifyReque
void HandlerTargetInformation::onRemoveTargetInformationRequest(const rti::core::SampleIdentity &cookie,
const RemoveTargetInformationRequest &request)
{
TRACE_LOG(m_logger) << Q_FUNC_INFO << " request=" << request;
TRACE_LOG(m_logger) << LOGFUNCTION << " request=" << request;
Core::FunctionReplyObject ret;
ObjectTargetInformation *ifs = m_objectMap.value(request.id());
@@ -8,7 +8,7 @@
#pragma once
#include <QtCore/QObject>
#include <QObject>
#include "dds_handler.h"
#include <ParticipantManagement/logger.h>
@@ -44,8 +44,6 @@ public:
}
private: // methods
NGL::INGLLogger &m_logger;
void onModifyTargetInformationRequest(const rti::core::SampleIdentity &cookie,
const ModifyTargetInformationRequest &request) override;
Core::FunctionReplyObject targetInformationModifyRequest(const ModifyTargetInformationRequest &request);
@@ -56,7 +54,7 @@ private: // attributes
QHash<int, ObjectTargetInformation *> m_objectMap;
MainHandler *m_mainHandler;
NGL::INGLLogger &m_logger; ///< Interface to the Logging-Facility
};
} // namespace ParticipantManagement
@@ -9,8 +9,8 @@
#include "object_target_information.h"
#include "../main_handler.h"
#include <QtCore/QJsonDocument>
#include <QtCore/QDebug>
#include <QJsonDocument>
#include <QDebug>
//------------------------------------------------------------------------------
@@ -108,19 +108,21 @@ std::vector<ShootbackArea> vecfromJson(const QJsonValue &val)
}
ObjectTargetInformation::ObjectTargetInformation(MainHandler *mainHandler) : m_mainHandler(mainHandler),
m_logger(NGL::NGLLoggerBootstrap::getNGLRootLogger()) {
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START";
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
ObjectTargetInformation::ObjectTargetInformation(MainHandler *mainHandler)
: m_mainHandler(mainHandler)
, m_logger(getLogger("ObjectTargetInformation"))
{
TRACE_LOG(m_logger) << LOGFUNCTION << " START";
TRACE_LOG(m_logger) << LOGFUNCTION << " END";
}
//------------------------------------------------------------------------------
ObjectTargetInformation::~ObjectTargetInformation()
{
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START";
TRACE_LOG(m_logger) << LOGFUNCTION << " START";
if (isValid())
m_mainHandler->dts()->removeTargetInformationByKey(m_data.id());
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
TRACE_LOG(m_logger) << LOGFUNCTION << " END";
}
//------------------------------------------------------------------------------
@@ -132,7 +134,7 @@ bool ObjectTargetInformation::isValid() const
//------------------------------------------------------------------------------
Core::FunctionReplyObject ObjectTargetInformation::createObject(const TargetInformation &data)
{
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START";
TRACE_LOG(m_logger) << LOGFUNCTION << " START";
m_data = data;
if (m_data.id() <= 0)
@@ -149,14 +151,14 @@ Core::FunctionReplyObject ObjectTargetInformation::createObject(const TargetInfo
// Publish Data via DTS
onPublishData();
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
TRACE_LOG(m_logger) << LOGFUNCTION << " END";
return Core::FunctionReplyObject(m_data.id());
}
//------------------------------------------------------------------------------
Core::FunctionReplyObject ObjectTargetInformation::updateObject(const TargetInformation &data)
{
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START, participantId=" << data.participantId()
TRACE_LOG(m_logger) << LOGFUNCTION << " START, participantId=" << data.participantId()
<< " size =" << data.shootbackAreas().size();
Database::PpmTargetInformation dbData;
dbData = toDbData(data);
@@ -170,7 +172,7 @@ Core::FunctionReplyObject ObjectTargetInformation::updateObject(const TargetInfo
// Publish Data via DTS
onPublishData();
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END, id=" << data.id()
TRACE_LOG(m_logger) << LOGFUNCTION << " END, id=" << data.id()
<< " size =" << data.shootbackAreas().size();
return Core::FunctionReplyObject(m_data.id());
}
@@ -178,7 +180,7 @@ Core::FunctionReplyObject ObjectTargetInformation::updateObject(const TargetInfo
//------------------------------------------------------------------------------
Core::FunctionReplyObject ObjectTargetInformation::removeObject()
{
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START";
TRACE_LOG(m_logger) << LOGFUNCTION << " START";
if (!m_mainHandler->db()->removePpmTargetInformation(m_data.id()))
return Core::FunctionReplyObject(m_data.id(), tr_lts("dds", "TargetInformation with id %1 can not be removed from DB")).arg(m_data.id());
@@ -186,7 +188,7 @@ Core::FunctionReplyObject ObjectTargetInformation::removeObject()
if (!m_mainHandler->dts()->removeTargetInformationByKey(m_data.id()))
return Core::FunctionReplyObject(m_data.id(), tr_lts("dds", "TargetInformation with id %1 can not be removed from DDS")).arg(m_data.id());
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
TRACE_LOG(m_logger) << LOGFUNCTION << " END";
return Core::FunctionReplyObject(m_data.id());
}
@@ -10,7 +10,7 @@
#include "dds_handler.h"
#include <ParticipantManagement/logger.h>
#include <Core/core_types.h>
#include <DDS/Core/function_reply_object.h>
// Generated
#include <ParticipantManagement/ppm.hpp>
@@ -46,11 +46,12 @@ public:
static TargetInformation toDdsData(const Database::PpmTargetInformation &dbData); // db -> dds
protected:
NGL::INGLLogger &m_logger;
void onPublishData();
private:
MainHandler *m_mainHandler;
TargetInformation m_data;
NGL::INGLLogger &m_logger;
};
}