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:
1 parent
c143ff8a4f
commit
d5af8b9764
1244 files changed
+4266
-4633
No files matched your search
@@ -32,14 +32,12 @@ CODEGEN_TOPIC_TYPEDEFS(SRCS_common ${xml_FILE})
|
||||
# generate pre_[d|f]tc.h
|
||||
CODEGEN_CLIENT_TOPICS_IFC(SRCS_common ${xml_FILE})
|
||||
|
||||
NGL_ADD_LIBRARY2(AAR SV WS svcPreCommon SHARED ${SRCS_common})
|
||||
NGL_ADD_LIBRARY(AAR SV WS svcPreCommon SHARED ${SRCS_common})
|
||||
NGL_TARGET_INCLUDE_DIRECTORIES(svcPreCommon
|
||||
PUBLIC
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/../
|
||||
${CMAKE_CURRENT_BINARY_DIR}/../
|
||||
${CMAKE_CURRENT_BINARY_DIR}
|
||||
)
|
||||
IF(BUILD_RTI)
|
||||
NGL_TARGET_LINK_LIBRARIES(svcPreCommon
|
||||
PRIVATE
|
||||
RTI::nddscpp2
|
||||
@@ -49,7 +47,6 @@ NGL_TARGET_LINK_LIBRARIES(svcPreCommon
|
||||
NGLLogger
|
||||
ngldb
|
||||
)
|
||||
ENDIF(BUILD_RTI)
|
||||
NGL_INSTALL_TARGET(svcPreCommon)
|
||||
|
||||
#
|
||||
@@ -61,14 +58,13 @@ SET(SRCS_client
|
||||
# generate pre_[d|f]tc_impl.[cpp|h]
|
||||
CODEGEN_CLIENT_TOPICS_IMPL(SRCS_client ${xml_FILE})
|
||||
|
||||
NGL_ADD_LIBRARY2(AAR SV WS svcPreClient SHARED ${SRCS_client})
|
||||
NGL_ADD_LIBRARY(AAR SV WS svcPreClient SHARED ${SRCS_client})
|
||||
NGL_TARGET_INCLUDE_DIRECTORIES(svcPreClient
|
||||
PUBLIC
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/../
|
||||
${CMAKE_CURRENT_BINARY_DIR}/../
|
||||
)
|
||||
|
||||
IF(BUILD_RTI)
|
||||
NGL_TARGET_LINK_LIBRARIES(svcPreClient
|
||||
PRIVATE
|
||||
RTI::nddscpp2
|
||||
@@ -77,7 +73,6 @@ NGL_TARGET_LINK_LIBRARIES(svcPreClient
|
||||
svcPreCommon
|
||||
ddsftc
|
||||
)
|
||||
ENDIF(BUILD_RTI)
|
||||
NGL_INSTALL_TARGET(svcPreClient)
|
||||
|
||||
#
|
||||
@@ -101,14 +96,13 @@ CODEGEN_SERVER_TOPICS(SRCS_server ${xml_FILE})
|
||||
# Generate pre.sql, pre.xml
|
||||
CODEGEN_SQL(SRCS_server ${xml_FILE})
|
||||
|
||||
NGL_ADD_LIBRARY2(AAR SV svcPreServer SHARED ${SRCS_server})
|
||||
NGL_ADD_LIBRARY(AAR SV svcPreServer SHARED ${SRCS_server})
|
||||
NGL_TARGET_INCLUDE_DIRECTORIES(svcPreServer
|
||||
PUBLIC
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/../
|
||||
${CMAKE_CURRENT_BINARY_DIR}/../
|
||||
)
|
||||
|
||||
IF(BUILD_RTI)
|
||||
NGL_TARGET_LINK_LIBRARIES(svcPreServer
|
||||
PRIVATE
|
||||
RTI::nddscpp2
|
||||
@@ -121,7 +115,6 @@ NGL_TARGET_LINK_LIBRARIES(svcPreServer
|
||||
svcPreCommon
|
||||
ngldb
|
||||
)
|
||||
ENDIF(BUILD_RTI)
|
||||
NGL_INSTALL_TARGET(svcPreServer)
|
||||
|
||||
#
|
||||
|
||||
+3
-2
@@ -11,8 +11,8 @@
|
||||
|
||||
#include <nglapplication/nglcoreapplication.h>
|
||||
#include <LtsCommandLineParser/LtsCommandLineParser.h>
|
||||
#include <QtCore/QTimer>
|
||||
#include <QtTest/QTest>
|
||||
#include <QTimer>
|
||||
#include <QTest>
|
||||
|
||||
#include <PresentationManagement/pre_ftc.h>
|
||||
|
||||
@@ -25,6 +25,7 @@ PreTests::PreTests(QObject *parent)
|
||||
, m_testId(0)
|
||||
, m_presentationId(0)
|
||||
, m_bTestsSuccessful(true)
|
||||
, m_logger(getLogger("Test"))
|
||||
{
|
||||
qRegisterMetaType<Core::FunctionReply>("Core::FunctionReply");
|
||||
}
|
||||
|
||||
+1
-1
@@ -26,7 +26,7 @@
|
||||
#include <PresentationManagement/logger.h>
|
||||
|
||||
#include <DDS/DDSConnector/dds_connector.h>
|
||||
#include <QtCore/QObject>
|
||||
#include <QObject>
|
||||
|
||||
namespace PresentationManagement
|
||||
{
|
||||
|
||||
@@ -13,6 +13,7 @@ namespace PresentationManagement
|
||||
|
||||
DdsHandler::DdsHandler(const std::shared_ptr<DDSConnector::DdsConnector> &ddsConnector)
|
||||
: m_ddsConnector(ddsConnector)
|
||||
, m_logger(getLogger("DdsHandler"))
|
||||
{
|
||||
DEBUG_LOG(m_logger) << "DdsHandler(" << m_ddsConnector->getDomainId() << ") for partition: " << m_ddsConnector->getDefaultPartition();
|
||||
}
|
||||
|
||||
@@ -45,11 +45,12 @@ public:
|
||||
}
|
||||
|
||||
private:
|
||||
NGL::INGLLogger &m_logger;
|
||||
std::shared_ptr<DDSConnector::DdsConnector> m_ddsConnector;
|
||||
std::shared_ptr<Core::TopicLockMaster> m_topicLockMaster;
|
||||
std::shared_ptr<PresentationManagement::Interface::Dts> m_ddsDts;
|
||||
std::shared_ptr<PresentationManagement::Interface::Fts> m_ddsFts;
|
||||
|
||||
NGL::INGLLogger &m_logger;
|
||||
};
|
||||
|
||||
}
|
||||
+2
-2
@@ -8,7 +8,6 @@
|
||||
*/
|
||||
|
||||
#include "handler_presentation.h"
|
||||
#include <utility>
|
||||
#include "object_presentation.h"
|
||||
#include "initialization.h"
|
||||
#include "dds_handler.h"
|
||||
@@ -24,6 +23,7 @@ HandlerPresentation::HandlerPresentation(Initialization *mainHandler)
|
||||
, Interface::Fts::GetPresentationContentRequestHandler(mainHandler->dds()->fts())
|
||||
, Interface::Fts::PresentationChangeStatusRequestHandler(mainHandler->dds()->fts())
|
||||
, m_mainHandler(mainHandler)
|
||||
, m_logger(getLogger("HandlerPresentation"))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -73,7 +73,7 @@ bool HandlerPresentation::init()
|
||||
}
|
||||
|
||||
// publish
|
||||
for (ObjectPresentation *objPre : std::as_const(m_objectPresentationMap))
|
||||
for (ObjectPresentation *objPre : qAsConst(m_objectPresentationMap))
|
||||
objPre->onPublishData();
|
||||
|
||||
return true;
|
||||
|
||||
+3
-4
@@ -9,8 +9,8 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <QtCore/QMap>
|
||||
#include <QtCore/QSet>
|
||||
#include <QMap>
|
||||
#include <QSet>
|
||||
|
||||
#include <PresentationManagement/pre_fts.h>
|
||||
|
||||
@@ -44,7 +44,6 @@ public:
|
||||
}
|
||||
|
||||
private:
|
||||
NGL::INGLLogger &m_logger;
|
||||
void onPresentationModifyRequest(const rti::core::SampleIdentity &cookie,
|
||||
const PresentationModifyRequest &request) override;
|
||||
Core::FunctionReplyObject presentationCreateRequest(const PresentationModifyRequest &request);
|
||||
@@ -57,8 +56,8 @@ private:
|
||||
const PresentationChangeStatusRequest &request) override;
|
||||
|
||||
private:
|
||||
NGL::INGLLogger &m_logger;
|
||||
Initialization *m_mainHandler;
|
||||
QMap<int, ObjectPresentation *> m_objectPresentationMap;
|
||||
NGL::INGLLogger &m_logger;
|
||||
};
|
||||
}
|
||||
@@ -19,6 +19,7 @@ namespace PresentationManagement
|
||||
|
||||
Initialization::Initialization(QObject *parent)
|
||||
: QObject(parent)
|
||||
, m_logger(getLogger("Initialization"))
|
||||
{
|
||||
qsrand(time(nullptr));
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include <QtCore/QObject>
|
||||
#include <QObject>
|
||||
#include <PresentationManagement/pre_db.h>
|
||||
|
||||
#include "logger.h"
|
||||
@@ -42,10 +42,9 @@ public:
|
||||
int exerciseId() const;
|
||||
|
||||
private:
|
||||
|
||||
NGL::INGLLogger &m_logger;
|
||||
std::shared_ptr<DdsHandler> m_ddsHandler;
|
||||
std::shared_ptr<DbHandler> m_dbHandler;
|
||||
std::shared_ptr<HandlerPresentation> m_handlerPresentation;
|
||||
LOGGER_T m_logger;
|
||||
};
|
||||
} // namespace AreaEffectSimulation
|
||||
@@ -9,7 +9,7 @@
|
||||
#pragma once
|
||||
|
||||
#include <NGLLogger/INGLLogger.h>
|
||||
#include "svcprecommon_export.h"
|
||||
#include "pre_export.h"
|
||||
|
||||
namespace PresentationManagement
|
||||
{
|
||||
|
||||
+6
-4
@@ -8,7 +8,6 @@
|
||||
*/
|
||||
|
||||
#include "object_presentation.h"
|
||||
#include <utility>
|
||||
#include "initialization.h"
|
||||
#include "dds_handler.h"
|
||||
#include <ngldb/dbtransaction.h>
|
||||
@@ -16,13 +15,16 @@
|
||||
namespace PresentationManagement
|
||||
{
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
ObjectPresentation::ObjectPresentation(Initialization *mainHandler) : m_mainHandler(mainHandler),
|
||||
m_logger(NGL::NGLLoggerBootstrap::getNGLRootLogger()) {
|
||||
ObjectPresentation::ObjectPresentation(Initialization *mainHandler)
|
||||
: m_mainHandler(mainHandler)
|
||||
, m_logger(getLogger("ObjectPresentation"))
|
||||
{
|
||||
}
|
||||
|
||||
ObjectPresentation::ObjectPresentation(const Presentation &data, Initialization *mainHandler)
|
||||
: m_mainHandler(mainHandler)
|
||||
, m_data(data)
|
||||
, m_logger(getLogger("ObjectPresentation"))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -110,7 +112,7 @@ Core::FunctionReplyObject ObjectPresentation::updateObject(const PresentationMod
|
||||
if (!m_mainHandler->db()->update(dbData))
|
||||
return Core::FunctionReplyObject(m_data.id(), tr_lts("dds", "Error updating Presentation-data into database"));
|
||||
|
||||
for (const auto &content : std::as_const(m_content))
|
||||
for (const auto &content : qAsConst(m_content))
|
||||
{
|
||||
if (m_mainHandler->db()->removePrePresentationContent(content.id()))
|
||||
DEBUG_LOG(m_logger) << "Removed presentation content id " << content.id();
|
||||
|
||||
+3
-3
@@ -9,8 +9,8 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <QtCore/QMap>
|
||||
#include <Core/core_types.h>
|
||||
#include <QMap>
|
||||
#include <DDS/Core/function_reply_object.h>
|
||||
|
||||
#include <PresentationManagement/pre_db.h>
|
||||
#include <PresentationManagement/pre.hpp>
|
||||
@@ -54,9 +54,9 @@ public:
|
||||
void onPublishData();
|
||||
|
||||
private:
|
||||
NGL::INGLLogger &m_logger;
|
||||
Initialization *m_mainHandler;
|
||||
Presentation m_data;
|
||||
std::vector<PresentationContent> m_content;
|
||||
NGL::INGLLogger &m_logger;
|
||||
};
|
||||
}
|
||||
@@ -6,7 +6,7 @@
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
#include <QtCore/QString>
|
||||
#include <QString>
|
||||
|
||||
namespace NGL
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user