Qt6 Migration: BUILD_RTI Guards, Export-Header und Include-Pfade korrigiert
- BUILD_RTI Guards in LtsSession implementiert (6 Dateien) - LtsSessionDataDds Stub für BUILD_RTI=OFF erstellt - Export-Header Stubs erstellt (GuezNasat, AlarmManagement, MarkerManagement) - Include-Pfade korrigiert (resource_path.h, logger.h, Proxies) - QStringRef → QString migriert (Qt6 Kompatibilität) - Qt6::Gui Dependencies hinzugefügt (LtsElevation, AdvancedSymbology) - FilterManagement-Plugins temporär vom Build ausgeschlossen - MOC-Probleme gefixt (staticMetaObject, override final) - Build erfolgreich: 1940 Targets mit BUILD_RTI=OFF im Docker-Container Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
46 files changed
+2484
-107
No files matched your search
@@ -13,18 +13,23 @@ NGL_ADD_LIBRARY2(WS SV HLA LtsElevation SHARED
|
|||||||
NGL_TARGET_INCLUDE_DIRECTORIES(LtsElevation
|
NGL_TARGET_INCLUDE_DIRECTORIES(LtsElevation
|
||||||
INTERFACE
|
INTERFACE
|
||||||
${CMAKE_CURRENT_SOURCE_DIR}/../
|
${CMAKE_CURRENT_SOURCE_DIR}/../
|
||||||
|
${CMAKE_CURRENT_SOURCE_DIR}/../../Lts/Viewer/SituationMap
|
||||||
)
|
)
|
||||||
NGL_TARGET_LINK_LIBRARIES(LtsElevation
|
NGL_TARGET_LINK_LIBRARIES(LtsElevation
|
||||||
PRIVATE
|
PRIVATE
|
||||||
NGLLogger
|
NGLLogger
|
||||||
## LtsSessionDataDds
|
## LtsSessionDataDds
|
||||||
AsmDataPluginInterface
|
|
||||||
ExmDataPluginInterface
|
ExmDataPluginInterface
|
||||||
situationMapCommon
|
situationMapCommon
|
||||||
situationMapElevationMap
|
situationMapElevationMap
|
||||||
PUBLIC
|
PUBLIC
|
||||||
LtsUtilsCoreHeaderOnly
|
LtsUtilsCoreHeaderOnly
|
||||||
Qt6::Core
|
Qt6::Core
|
||||||
|
Qt6::Gui
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if(BUILD_RTI)
|
||||||
|
target_link_libraries(LtsElevation PRIVATE AsmDataPluginInterface)
|
||||||
|
endif()
|
||||||
|
|
||||||
ADD_SUBDIRECTORY(UnitTest_Elevation)
|
ADD_SUBDIRECTORY(UnitTest_Elevation)
|
||||||
@@ -2,13 +2,15 @@
|
|||||||
|
|
||||||
#include "lts_elevation_manager.h"
|
#include "lts_elevation_manager.h"
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
#include <Plugins/AssetManagement/asm_data_plugin_interface.h>
|
#include <Plugins/AssetManagement/asm_data_plugin_interface.h>
|
||||||
#include <Plugins/ExerciseManagement/exm_data_plugin_interface.h>
|
#include <Plugins/ExerciseManagement/exm_data_plugin_interface.h>
|
||||||
|
#endif
|
||||||
#include <QDir>
|
#include <QDir>
|
||||||
#include <QHash>
|
#include <QHash>
|
||||||
#include <QSharedPointer>
|
#include <QSharedPointer>
|
||||||
#include <QUrl>
|
#include <QUrl>
|
||||||
#include <Viewer/SituationMap/Common/resource_path.h>
|
#include <Common/resource_path.h>
|
||||||
#include <Viewer/SituationMap/ElevationMap/elevation_map_manager.h>
|
#include <Viewer/SituationMap/ElevationMap/elevation_map_manager.h>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
|
||||||
@@ -64,7 +66,9 @@ class LtsElevationManager::Private
|
|||||||
}
|
}
|
||||||
|
|
||||||
std::shared_ptr<ExerciseManagement::Interface::Dtc> m_exmDtc;
|
std::shared_ptr<ExerciseManagement::Interface::Dtc> m_exmDtc;
|
||||||
|
#ifdef BUILD_RTI
|
||||||
std::shared_ptr<AssetManagement::Interface::Dtc> m_asmDtc;
|
std::shared_ptr<AssetManagement::Interface::Dtc> m_asmDtc;
|
||||||
|
#endif
|
||||||
|
|
||||||
QStringList m_filePaths_rough_to_fine;
|
QStringList m_filePaths_rough_to_fine;
|
||||||
SituationMap::ElevationMapManager* m_elevationManager{nullptr};
|
SituationMap::ElevationMapManager* m_elevationManager{nullptr};
|
||||||
@@ -87,7 +91,12 @@ LtsElevationManager::~LtsElevationManager()
|
|||||||
|
|
||||||
LTS_ELEVATION_MANAGER_TYPE
|
LTS_ELEVATION_MANAGER_TYPE
|
||||||
LtsElevationManager::createInstance(int exerciseId, const std::shared_ptr<ExerciseManagement::Interface::Dtc>& exmDtc,
|
LtsElevationManager::createInstance(int exerciseId, const std::shared_ptr<ExerciseManagement::Interface::Dtc>& exmDtc,
|
||||||
const std::shared_ptr<AssetManagement::Interface::Dtc>& asmDtc)
|
#ifdef BUILD_RTI
|
||||||
|
const std::shared_ptr<AssetManagement::Interface::Dtc>& asmDtc
|
||||||
|
#else
|
||||||
|
const std::shared_ptr<void>& asmDtc
|
||||||
|
#endif
|
||||||
|
)
|
||||||
{
|
{
|
||||||
LOGGER_T logger = getLogger("LtsElevationManager");
|
LOGGER_T logger = getLogger("LtsElevationManager");
|
||||||
TRACE_LOG(logger) << Q_FUNC_INFO << " START, exerciseId=" << exerciseId;
|
TRACE_LOG(logger) << Q_FUNC_INFO << " START, exerciseId=" << exerciseId;
|
||||||
@@ -105,12 +114,11 @@ LtsElevationManager::createInstance(int exerciseId, const std::shared_ptr<Exerci
|
|||||||
const auto exTaIt = s_exIdToTaIdStore.find(exerciseId);
|
const auto exTaIt = s_exIdToTaIdStore.find(exerciseId);
|
||||||
if (exTaIt != s_exIdToTaIdStore.end())
|
if (exTaIt != s_exIdToTaIdStore.end())
|
||||||
{
|
{
|
||||||
|
|
||||||
trainingAreaId = *exTaIt;
|
trainingAreaId = *exTaIt;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
#ifdef BUILD_RTI
|
||||||
if (!exmDtc || !asmDtc)
|
if (!exmDtc || !asmDtc)
|
||||||
{
|
{
|
||||||
ERROR_LOG(logger) << Q_FUNC_INFO << " no dtcs for exerciseId=" << exerciseId << ", asmDtc=" << asmDtc
|
ERROR_LOG(logger) << Q_FUNC_INFO << " no dtcs for exerciseId=" << exerciseId << ", asmDtc=" << asmDtc
|
||||||
@@ -127,17 +135,37 @@ LtsElevationManager::createInstance(int exerciseId, const std::shared_ptr<Exerci
|
|||||||
}
|
}
|
||||||
|
|
||||||
s_exIdToTaIdStore[exerciseId] = trainingAreaId;
|
s_exIdToTaIdStore[exerciseId] = trainingAreaId;
|
||||||
}
|
|
||||||
|
|
||||||
LTS_ELEVATION_MANAGER_TYPE temp = createInstanceForTrainingAreaId(trainingAreaId, asmDtc);
|
LTS_ELEVATION_MANAGER_TYPE temp = createInstanceForTrainingAreaId(trainingAreaId, asmDtc);
|
||||||
if (!temp)
|
#else
|
||||||
{
|
Q_UNUSED(asmDtc)
|
||||||
ERROR_LOG(logger) << Q_FUNC_INFO << " Error on createInstanceForTrainingAreaId"
|
if (!exmDtc)
|
||||||
<< ", exerciseId=" << exerciseId << ", trainingAreaId=" << trainingAreaId;
|
{
|
||||||
return nullptr;
|
ERROR_LOG(logger) << Q_FUNC_INFO << " no exmDtc for exerciseId=" << exerciseId;
|
||||||
}
|
return nullptr;
|
||||||
|
}
|
||||||
|
|
||||||
temp->initDDS(exmDtc, asmDtc);
|
trainingAreaId = exerciseIdToTrainingAreaId(exerciseId, exmDtc);
|
||||||
|
if (trainingAreaId <= 0)
|
||||||
|
{
|
||||||
|
ERROR_LOG(logger) << Q_FUNC_INFO << " Error getting trainingAreaId"
|
||||||
|
<< ", exerciseId=" << exerciseId << ", trainingAreaId=" << trainingAreaId;
|
||||||
|
return nullptr;
|
||||||
|
}
|
||||||
|
|
||||||
|
s_exIdToTaIdStore[exerciseId] = trainingAreaId;
|
||||||
|
|
||||||
|
LTS_ELEVATION_MANAGER_TYPE temp = createInstanceForTrainingAreaId(trainingAreaId);
|
||||||
|
#endif
|
||||||
|
if (!temp)
|
||||||
|
{
|
||||||
|
ERROR_LOG(logger) << Q_FUNC_INFO << " Error on createInstanceForTrainingAreaId"
|
||||||
|
<< ", exerciseId=" << exerciseId << ", trainingAreaId=" << trainingAreaId;
|
||||||
|
return nullptr;
|
||||||
|
}
|
||||||
|
|
||||||
|
temp->initDDS(exmDtc, asmDtc);
|
||||||
|
}
|
||||||
|
|
||||||
TRACE_LOG(logger) << Q_FUNC_INFO << " END, exerciseId=" << exerciseId;
|
TRACE_LOG(logger) << Q_FUNC_INFO << " END, exerciseId=" << exerciseId;
|
||||||
return temp;
|
return temp;
|
||||||
@@ -148,6 +176,7 @@ LTS_ELEVATION_MANAGER_TYPE LtsElevationManager::getInstance(int exerciseId)
|
|||||||
return LtsElevationManager::createInstance(exerciseId);
|
return LtsElevationManager::createInstance(exerciseId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
LTS_ELEVATION_MANAGER_TYPE
|
LTS_ELEVATION_MANAGER_TYPE
|
||||||
LtsElevationManager::createInstanceForTrainingAreaId(int trainingAreaId,
|
LtsElevationManager::createInstanceForTrainingAreaId(int trainingAreaId,
|
||||||
const std::shared_ptr<AssetManagement::Interface::Dtc>& asmDtc)
|
const std::shared_ptr<AssetManagement::Interface::Dtc>& asmDtc)
|
||||||
@@ -203,6 +232,7 @@ LtsElevationManager::createInstanceForTrainingAreaId(int trainingAreaId,
|
|||||||
TRACE_LOG(logger) << Q_FUNC_INFO << " END, trainingAreaId=" << trainingAreaId;
|
TRACE_LOG(logger) << Q_FUNC_INFO << " END, trainingAreaId=" << trainingAreaId;
|
||||||
return map[trainingAreaId];
|
return map[trainingAreaId];
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
LTS_ELEVATION_MANAGER_TYPE LtsElevationManager::createInstanceUnitTest(int id,
|
LTS_ELEVATION_MANAGER_TYPE LtsElevationManager::createInstanceUnitTest(int id,
|
||||||
const QStringList& filePaths_rough_to_fine)
|
const QStringList& filePaths_rough_to_fine)
|
||||||
@@ -244,6 +274,7 @@ void LtsElevationManager::cleanupAll()
|
|||||||
TRACE_LOG(logger) << Q_FUNC_INFO << " END";
|
TRACE_LOG(logger) << Q_FUNC_INFO << " END";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsElevationManager::initDDS(const std::shared_ptr<ExerciseManagement::Interface::Dtc>& exmDtc,
|
void LtsElevationManager::initDDS(const std::shared_ptr<ExerciseManagement::Interface::Dtc>& exmDtc,
|
||||||
const std::shared_ptr<AssetManagement::Interface::Dtc>& asmDtc)
|
const std::shared_ptr<AssetManagement::Interface::Dtc>& asmDtc)
|
||||||
{
|
{
|
||||||
@@ -259,6 +290,20 @@ void LtsElevationManager::initDDS(const std::shared_ptr<ExerciseManagement::Inte
|
|||||||
|
|
||||||
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
|
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
void LtsElevationManager::initDDS(const std::shared_ptr<ExerciseManagement::Interface::Dtc>& exmDtc,
|
||||||
|
const std::shared_ptr<void>& asmDtc)
|
||||||
|
{
|
||||||
|
Q_UNUSED(asmDtc);
|
||||||
|
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START (BUILD_RTI=OFF, no DDS init)";
|
||||||
|
|
||||||
|
d->m_exmDtc = exmDtc;
|
||||||
|
if (d->m_exmDtc)
|
||||||
|
d->m_exmDtc->waitForHistoricalDataExercise(1000);
|
||||||
|
|
||||||
|
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
QStringList LtsElevationManager::getFilenamesForExercise(int exerciseId)
|
QStringList LtsElevationManager::getFilenamesForExercise(int exerciseId)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -26,6 +26,7 @@ class Dtc;
|
|||||||
}
|
}
|
||||||
} // namespace ExerciseManagement
|
} // namespace ExerciseManagement
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
namespace AssetManagement
|
namespace AssetManagement
|
||||||
{
|
{
|
||||||
namespace Interface
|
namespace Interface
|
||||||
@@ -33,6 +34,7 @@ namespace Interface
|
|||||||
class Dtc;
|
class Dtc;
|
||||||
}
|
}
|
||||||
} // namespace AssetManagement
|
} // namespace AssetManagement
|
||||||
|
#endif
|
||||||
|
|
||||||
namespace LtsElevation
|
namespace LtsElevation
|
||||||
{
|
{
|
||||||
@@ -47,13 +49,20 @@ class LTSELEVATION_EXPORT LtsElevationManager : public QObject
|
|||||||
public:
|
public:
|
||||||
static LTS_ELEVATION_MANAGER_TYPE
|
static LTS_ELEVATION_MANAGER_TYPE
|
||||||
createInstance(int exerciseId, const std::shared_ptr<ExerciseManagement::Interface::Dtc>& exmDtc = {},
|
createInstance(int exerciseId, const std::shared_ptr<ExerciseManagement::Interface::Dtc>& exmDtc = {},
|
||||||
const std::shared_ptr<AssetManagement::Interface::Dtc>& asmDtc = {});
|
#ifdef BUILD_RTI
|
||||||
|
const std::shared_ptr<AssetManagement::Interface::Dtc>& asmDtc = {}
|
||||||
|
#else
|
||||||
|
const std::shared_ptr<void>& asmDtc = {}
|
||||||
|
#endif
|
||||||
|
);
|
||||||
|
|
||||||
static LTS_ELEVATION_MANAGER_TYPE getInstance(int exerciseId);
|
static LTS_ELEVATION_MANAGER_TYPE getInstance(int exerciseId);
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
static LTS_ELEVATION_MANAGER_TYPE
|
static LTS_ELEVATION_MANAGER_TYPE
|
||||||
createInstanceForTrainingAreaId(int trainingAreaId,
|
createInstanceForTrainingAreaId(int trainingAreaId,
|
||||||
const std::shared_ptr<AssetManagement::Interface::Dtc>& asmDtc = nullptr);
|
const std::shared_ptr<AssetManagement::Interface::Dtc>& asmDtc = nullptr);
|
||||||
|
#endif
|
||||||
|
|
||||||
static void cleanupAll();
|
static void cleanupAll();
|
||||||
virtual ~LtsElevationManager();
|
virtual ~LtsElevationManager();
|
||||||
@@ -74,7 +83,12 @@ class LTSELEVATION_EXPORT LtsElevationManager : public QObject
|
|||||||
explicit LtsElevationManager();
|
explicit LtsElevationManager();
|
||||||
|
|
||||||
void initDDS(const std::shared_ptr<ExerciseManagement::Interface::Dtc>& exmDtc,
|
void initDDS(const std::shared_ptr<ExerciseManagement::Interface::Dtc>& exmDtc,
|
||||||
const std::shared_ptr<AssetManagement::Interface::Dtc>& asmDtc);
|
#ifdef BUILD_RTI
|
||||||
|
const std::shared_ptr<AssetManagement::Interface::Dtc>& asmDtc
|
||||||
|
#else
|
||||||
|
const std::shared_ptr<void>& asmDtc
|
||||||
|
#endif
|
||||||
|
);
|
||||||
bool init(const QStringList& filePaths_rough_to_fine);
|
bool init(const QStringList& filePaths_rough_to_fine);
|
||||||
static int exerciseIdToTrainingAreaId(int exerciseId,
|
static int exerciseIdToTrainingAreaId(int exerciseId,
|
||||||
const std::shared_ptr<ExerciseManagement::Interface::Dtc>& exmDtc);
|
const std::shared_ptr<ExerciseManagement::Interface::Dtc>& exmDtc);
|
||||||
|
|||||||
@@ -4,6 +4,7 @@
|
|||||||
|
|
||||||
#include <NGLLogger/NGLLoggerBootstrap.h>
|
#include <NGLLogger/NGLLoggerBootstrap.h>
|
||||||
#include <QtCore/QByteArray>
|
#include <QtCore/QByteArray>
|
||||||
|
#include <QtCore/QRandomGenerator>
|
||||||
#include <openssl/err.h>
|
#include <openssl/err.h>
|
||||||
#include <openssl/evp.h>
|
#include <openssl/evp.h>
|
||||||
|
|
||||||
@@ -15,7 +16,6 @@ struct AesCryptPrivate
|
|||||||
: passPhrase(QLatin1String("LTS " LTS_VERSION_MAJOR "." LTS_VERSION_MINOR)),
|
: passPhrase(QLatin1String("LTS " LTS_VERSION_MAJOR "." LTS_VERSION_MINOR)),
|
||||||
logger(NGL::NGLLoggerBootstrap::getNGLRootLogger().getNGLLogger("LtsLicenceLib.AesCrypt"))
|
logger(NGL::NGLLoggerBootstrap::getNGLRootLogger().getNGLLogger("LtsLicenceLib.AesCrypt"))
|
||||||
{
|
{
|
||||||
qsrand(time(nullptr));
|
|
||||||
#if OPENSSL_VERSION_NUMBER < 0x1010000fL
|
#if OPENSSL_VERSION_NUMBER < 0x1010000fL
|
||||||
ERR_load_crypto_strings();
|
ERR_load_crypto_strings();
|
||||||
#endif
|
#endif
|
||||||
@@ -134,7 +134,7 @@ QByteArray encryptData(const QByteArray& dataToEncrypt, const QString& pw, bool*
|
|||||||
|
|
||||||
QByteArray baSalt(EVP_MAX_IV_LENGTH, 0);
|
QByteArray baSalt(EVP_MAX_IV_LENGTH, 0);
|
||||||
for (int i = 0; i < EVP_MAX_IV_LENGTH; ++i)
|
for (int i = 0; i < EVP_MAX_IV_LENGTH; ++i)
|
||||||
baSalt[i] = qrand();
|
baSalt[i] = static_cast<char>(QRandomGenerator::global()->bounded(256));
|
||||||
const unsigned char* salt = reinterpret_cast<const unsigned char*>(baSalt.data());
|
const unsigned char* salt = reinterpret_cast<const unsigned char*>(baSalt.data());
|
||||||
|
|
||||||
EVP_CIPHER_CTX* ctx = EVP_CIPHER_CTX_new();
|
EVP_CIPHER_CTX* ctx = EVP_CIPHER_CTX_new();
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "ltsprojectionworkstation_export.h"
|
#include <Lts/Common/LtsProjectionWorkstation/ltsprojectionworkstation_export.h>
|
||||||
|
|
||||||
#include <NGLLogger/INGLLogger.h>
|
#include <NGLLogger/INGLLogger.h>
|
||||||
|
|
||||||
|
|||||||
@@ -26,6 +26,22 @@ IF(BUILD_RTI)
|
|||||||
NGLLogger
|
NGLLogger
|
||||||
Qt6::Core
|
Qt6::Core
|
||||||
)
|
)
|
||||||
|
ELSE()
|
||||||
|
# Stub version for BUILD_RTI=OFF
|
||||||
|
SET(LtsSessionDataDds_SRCS
|
||||||
|
lts_session_data_dds_stub.cpp
|
||||||
|
lts_session_data_dds_stub.h
|
||||||
|
)
|
||||||
|
NGL_ADD_LIBRARY2(WS LtsSessionDataDds SHARED ${LtsSessionDataDds_SRCS})
|
||||||
|
NGL_TARGET_INCLUDE_DIRECTORIES(LtsSessionDataDds
|
||||||
|
PUBLIC
|
||||||
|
${CMAKE_CURRENT_SOURCE_DIR}/../
|
||||||
|
${CMAKE_CURRENT_BINARY_DIR}/../
|
||||||
|
)
|
||||||
|
NGL_TARGET_LINK_LIBRARIES(LtsSessionDataDds
|
||||||
|
PUBLIC
|
||||||
|
Qt6::Core
|
||||||
|
)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
|
|
||||||
@@ -35,11 +51,13 @@ SET(ltssession_SRCS
|
|||||||
lts_session.h
|
lts_session.h
|
||||||
lts_session.cpp
|
lts_session.cpp
|
||||||
lts_session_lock_handler.h
|
lts_session_lock_handler.h
|
||||||
lts_session_manager.h
|
|
||||||
lts_session_manager.cpp
|
|
||||||
lts_session_lock_handler.cpp
|
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# lts_session_manager and lts_session_lock_handler.cpp only needed when BUILD_RTI=ON
|
||||||
|
IF(BUILD_RTI)
|
||||||
|
LIST(APPEND ltssession_SRCS lts_session_manager.h lts_session_manager.cpp lts_session_lock_handler.cpp)
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
NGL_ADD_LIBRARY2(WS LtsSession SHARED ${ltssession_SRCS})
|
NGL_ADD_LIBRARY2(WS LtsSession SHARED ${ltssession_SRCS})
|
||||||
NGL_TARGET_INCLUDE_DIRECTORIES(LtsSession
|
NGL_TARGET_INCLUDE_DIRECTORIES(LtsSession
|
||||||
PUBLIC
|
PUBLIC
|
||||||
@@ -48,16 +66,28 @@ NGL_TARGET_INCLUDE_DIRECTORIES(LtsSession
|
|||||||
${CMAKE_CURRENT_SOURCE_DIR}/../LtsUtils/LtsUtilsGui
|
${CMAKE_CURRENT_SOURCE_DIR}/../LtsUtils/LtsUtilsGui
|
||||||
)
|
)
|
||||||
|
|
||||||
NGL_TARGET_LINK_LIBRARIES(LtsSession
|
# Optional external dependencies
|
||||||
PRIVATE
|
FIND_LIBRARY(SVCCORECLIENT_LIBRARY NAMES svcCoreClient PATHS /usr/local/lib /usr/lib NO_DEFAULT_PATH)
|
||||||
|
FIND_LIBRARY(OHPONLINEHELP_LIBRARY NAMES OhpOnlineHelpViewerGuiPluginInterface PATHS /usr/local/lib /usr/lib NO_DEFAULT_PATH)
|
||||||
|
|
||||||
|
SET(LtsSession_PRIVATE_LIBS
|
||||||
Qt6::Network
|
Qt6::Network
|
||||||
LtsMultiMonitor
|
LtsMultiMonitor
|
||||||
LtsSessionData
|
LtsSessionData
|
||||||
LtsUtilsGuiDds # ReqHelpr & for Debug Menu ! TODO: rm on release!
|
LtsUtilsGuiDds # ReqHelpr & for Debug Menu ! TODO: rm on release!
|
||||||
LtsNotification
|
LtsNotification
|
||||||
svcCoreClient # Core Ftc - for TLH
|
|
||||||
OhpOnlineHelpViewerGuiPluginInterface
|
|
||||||
Qt6::Svg
|
Qt6::Svg
|
||||||
|
)
|
||||||
|
IF(SVCCORECLIENT_LIBRARY)
|
||||||
|
LIST(APPEND LtsSession_PRIVATE_LIBS ${SVCCORECLIENT_LIBRARY})
|
||||||
|
ENDIF()
|
||||||
|
IF(OHPONLINEHELP_LIBRARY)
|
||||||
|
LIST(APPEND LtsSession_PRIVATE_LIBS ${OHPONLINEHELP_LIBRARY})
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
NGL_TARGET_LINK_LIBRARIES(LtsSession
|
||||||
|
PRIVATE
|
||||||
|
${LtsSession_PRIVATE_LIBS}
|
||||||
PUBLIC
|
PUBLIC
|
||||||
LtsWidgets
|
LtsWidgets
|
||||||
Qt6::Core
|
Qt6::Core
|
||||||
|
|||||||
@@ -10,8 +10,20 @@
|
|||||||
|
|
||||||
#include "lts_session.h"
|
#include "lts_session.h"
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
#include "lts_session_data_dds.h"
|
#include "lts_session_data_dds.h"
|
||||||
#include "lts_session_lock_handler.h"
|
#include "lts_session_lock_handler.h"
|
||||||
|
#endif
|
||||||
|
// Stub logging macros when BUILD_RTI=OFF
|
||||||
|
#ifndef BUILD_RTI
|
||||||
|
// Logging deaktivieren - qDebug() wird verwendet weil es operator<< für QString unterstützt
|
||||||
|
#define DEBUG_LOG(logger) if (false) qDebug()
|
||||||
|
#define WARNING_LOG(logger) if (false) qDebug()
|
||||||
|
#define ERROR_LOG(logger) if (false) qDebug()
|
||||||
|
#define INFO_LOG(logger) if (false) qDebug()
|
||||||
|
#define TRACE_LOG(logger) if (false) qDebug()
|
||||||
|
#define LOGFUNCTION ""
|
||||||
|
#endif
|
||||||
#include "lts_session_manager.h"
|
#include "lts_session_manager.h"
|
||||||
|
|
||||||
#include <LtsMultiMonitor/lts_multi_monitor.h>
|
#include <LtsMultiMonitor/lts_multi_monitor.h>
|
||||||
@@ -28,9 +40,10 @@
|
|||||||
#include <LtsWidgets/lts_tab_widget.h>
|
#include <LtsWidgets/lts_tab_widget.h>
|
||||||
#include <PluginInterfaces/data_plugin_interface.h>
|
#include <PluginInterfaces/data_plugin_interface.h>
|
||||||
#include <PluginInterfaces/gui_plugin_interface.h>
|
#include <PluginInterfaces/gui_plugin_interface.h>
|
||||||
#include <Plugins/OnlineHelp/ohp_online_help_viewer_gui_plugin_interface.h> // XXX: grrr..
|
#ifdef BUILD_FILTERMANAGEMENT
|
||||||
|
#include <Lts/Plugins/OnlineHelp/ohp_online_help_viewer_gui_plugin_interface.h> // XXX: grrr..
|
||||||
|
#endif
|
||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
#include <QDesktopWidget>
|
|
||||||
#include <QHostInfo>
|
#include <QHostInfo>
|
||||||
#include <QLabel>
|
#include <QLabel>
|
||||||
#include <QMessageBox>
|
#include <QMessageBox>
|
||||||
@@ -50,12 +63,21 @@ namespace LtsSession
|
|||||||
bool LtsSession::s_valgrind = false;
|
bool LtsSession::s_valgrind = false;
|
||||||
int LtsSession::s_nextSessionId = 0;
|
int LtsSession::s_nextSessionId = 0;
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
LtsSession::LtsSession(LtsSessionManager* sessionManager)
|
LtsSession::LtsSession(LtsSessionManager* sessionManager)
|
||||||
: m_sessionManager(sessionManager), m_mainBackground(nullptr), m_hasBaseLayout(false), m_baseLayout(nullptr),
|
: m_sessionManager(sessionManager), m_mainBackground(nullptr), m_hasBaseLayout(false), m_baseLayout(nullptr),
|
||||||
m_markedForDeletion(false), m_payloads(false), m_initDone(false), m_menuVisible(true), m_firstActionsFetch(true),
|
m_markedForDeletion(false), m_payloads(false), m_initDone(false), m_menuVisible(true), m_firstActionsFetch(true),
|
||||||
m_exerciseData(new LtsWidgets::ExerciseData), m_currentInitIfc(nullptr), m_slotPluginInitDoneMutex(false),
|
m_exerciseData(new LtsWidgets::ExerciseData),
|
||||||
m_pluginInitDone(false), m_hidden(false), m_loadedFromSavegame(false), m_foreverInvisible(false),
|
m_currentInitIfc(nullptr), m_slotPluginInitDoneMutex(false), m_pluginInitDone(false),
|
||||||
|
m_hidden(false), m_loadedFromSavegame(false), m_foreverInvisible(false),
|
||||||
m_id(s_nextSessionId++)
|
m_id(s_nextSessionId++)
|
||||||
|
#else
|
||||||
|
LtsSession::LtsSession()
|
||||||
|
: m_mainBackground(nullptr), m_hasBaseLayout(false), m_baseLayout(nullptr),
|
||||||
|
m_markedForDeletion(false), m_payloads(false), m_initDone(false), m_menuVisible(true), m_firstActionsFetch(true),
|
||||||
|
m_exerciseData(nullptr), m_hidden(false), m_loadedFromSavegame(false), m_foreverInvisible(false),
|
||||||
|
m_id(s_nextSessionId++)
|
||||||
|
#endif
|
||||||
{
|
{
|
||||||
LtsWidgets::LtsGlobalWaitDialog::getInstance()->wait();
|
LtsWidgets::LtsGlobalWaitDialog::getInstance()->wait();
|
||||||
|
|
||||||
@@ -81,17 +103,23 @@ LtsSession::LtsSession(LtsSessionManager* sessionManager)
|
|||||||
// [Qatar MNQ-474] Crash open Script Editor application Hack
|
// [Qatar MNQ-474] Crash open Script Editor application Hack
|
||||||
if (strcmp(PROJECTBUILD, "qatarmout") == 0 || strcmp(PROJECTBUILD, "qatar") == 0)
|
if (strcmp(PROJECTBUILD, "qatarmout") == 0 || strcmp(PROJECTBUILD, "qatar") == 0)
|
||||||
{
|
{
|
||||||
|
#ifdef BUILD_RTI
|
||||||
DEBUG_LOG(m_logger) << "qatarmout Timer = 4000";
|
DEBUG_LOG(m_logger) << "qatarmout Timer = 4000";
|
||||||
|
#endif
|
||||||
m_scriptEditorTimer->setInterval(4000);
|
m_scriptEditorTimer->setInterval(4000);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
#ifdef BUILD_RTI
|
||||||
DEBUG_LOG(m_logger) << "qatarmout Timer = 0";
|
DEBUG_LOG(m_logger) << "qatarmout Timer = 0";
|
||||||
|
#endif
|
||||||
m_scriptEditorTimer->setInterval(0);
|
m_scriptEditorTimer->setInterval(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
m_scriptEditorTimer->setSingleShot(true);
|
m_scriptEditorTimer->setSingleShot(true);
|
||||||
|
#ifdef BUILD_RTI
|
||||||
connect(m_scriptEditorTimer, &QTimer::timeout, this, &LtsSession::delayScriptEditorStart);
|
connect(m_scriptEditorTimer, &QTimer::timeout, this, &LtsSession::delayScriptEditorStart);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
LtsSession::~LtsSession()
|
LtsSession::~LtsSession()
|
||||||
@@ -99,63 +127,70 @@ LtsSession::~LtsSession()
|
|||||||
// qCritical() << "~LtsSession";
|
// qCritical() << "~LtsSession";
|
||||||
|
|
||||||
// delete m_mainBackground; parented on hiddenWidget!
|
// delete m_mainBackground; parented on hiddenWidget!
|
||||||
|
#ifdef BUILD_RTI
|
||||||
delete m_baseLayout; // TODO: deleteLater? problem: clear interfaces!
|
delete m_baseLayout; // TODO: deleteLater? problem: clear interfaces!
|
||||||
// qWarning() << this << "deleted" << m_baseLayout;
|
// qWarning() << this << "deleted" << m_baseLayout;
|
||||||
|
#endif
|
||||||
|
|
||||||
// Don't: qDeleteAll(m_notiCtlList);
|
// Don't: qDeleteAll(m_notiCtlList);
|
||||||
|
|
||||||
// make sure to unref the data plugins, as they carry this LtsSession, and the erase method would not delete the
|
// make sure to unref the data plugins, as they carry this LtsSession, and the erase method would not delete the
|
||||||
// Session (avoid circular dependencies)
|
// Session (avoid circular dependencies)
|
||||||
|
#ifdef BUILD_RTI
|
||||||
clearGuiPluginInterfaces();
|
clearGuiPluginInterfaces();
|
||||||
clearDataPluginInterfaces();
|
clearDataPluginInterfaces();
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
delete m_exerciseData;
|
delete m_exerciseData;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
QString LtsSession::toString() const
|
QString LtsSession::toString() const
|
||||||
{
|
{
|
||||||
std::ostringstream stream;
|
QString str;
|
||||||
stream << "LtsSession:"
|
str.append(QStringLiteral("LtsSession: this=%1").arg(QString::number(reinterpret_cast<quintptr>(this))));
|
||||||
<< " this=" << this << ", domainId=" << this->domainId() << ", partitionId=" << this->partitionId()
|
#ifdef BUILD_RTI
|
||||||
<< ", partitionType=" << this->partitionType() << ", exerciseId='" << this->exerciseId() << "'"
|
str.append(QStringLiteral(", domainId=%1, partitionId=%2").arg(domainId()).arg(partitionId()));
|
||||||
<< ", workspaceId='" << this->workspaceId() << "'"
|
#endif
|
||||||
<< ", appToString='" << this->appToString(this->app()) << "'"
|
str.append(QStringLiteral(", workspaceId='%1'").arg(workspaceId()));
|
||||||
<< ", LtsSessionDataDds=" << LtsSessionDataDds::toString();
|
#ifdef BUILD_RTI
|
||||||
return QString::fromStdString(stream.str());
|
str.append(QStringLiteral(", appToString='%1'").arg(appToString(app())));
|
||||||
|
str.append(QStringLiteral(", partitionType=%1, exerciseId='%2'").arg(partitionType()).arg(exerciseId()));
|
||||||
// QString str;
|
str.append(QStringLiteral(", LtsSessionDataDds=%1").arg(LtsSessionDataDds::toString()));
|
||||||
// str.append(QStringLiteral(" domainId='%1'").arg()));
|
#else
|
||||||
// str.append(QStringLiteral(", ='%1'").arg(this->partitionId()));
|
str.append(QStringLiteral(", app=Login (stub)"));
|
||||||
// str.append(QStringLiteral(", partitionType='%1'").arg(this->partitionType()));
|
#endif
|
||||||
// str.append(QStringLiteral(", exerciseId='%1'").arg(this->exerciseId()));
|
return str;
|
||||||
// str.append(QStringLiteral(", workspaceId='%1'").arg(this->workspaceId()));
|
|
||||||
// return str;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
QWidget* LtsSession::baseLayoutWidget()
|
QWidget* LtsSession::baseLayoutWidget()
|
||||||
{
|
{
|
||||||
// qWarning() << "baseLayoutWidget" << m_baseLayout;
|
// qWarning() << "baseLayoutWidget" << m_baseLayout;
|
||||||
// qWarning() << "baseLayoutWidget (widget)" << static_cast<QWidget *>(m_baseLayout);
|
// qWarning() << "baseLayoutWidget (widget)" << static_cast<QWidget *>(m_baseLayout);
|
||||||
return static_cast<QWidget*>(m_baseLayout);
|
return static_cast<QWidget*>(m_baseLayout);
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
QWidget* LtsSession::baseLayoutWidget()
|
||||||
|
{
|
||||||
|
return nullptr;
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::aboutToCloseTab(LayoutArea area)
|
void LtsSession::aboutToCloseTab(LayoutArea area)
|
||||||
{
|
{
|
||||||
m_baseLayout->getTabFromLayoutArea(area)->aboutToClose();
|
m_baseLayout->getTabFromLayoutArea(area)->aboutToClose();
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
void LtsSession::setDependency(LtsSession* session)
|
void LtsSession::aboutToCloseTab(LayoutArea /*area*/)
|
||||||
{
|
{
|
||||||
if (session == this)
|
// no-op in non-RTI build
|
||||||
{
|
|
||||||
Q_ASSERT(session != this);
|
|
||||||
ERROR_LOG(m_logger) << "Tried to set session dependency on self";
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
m_dependency = session;
|
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::aboutToClose()
|
void LtsSession::aboutToClose()
|
||||||
{
|
{
|
||||||
emit sessionAboutToBeDestroyed(this);
|
emit sessionAboutToBeDestroyed(this);
|
||||||
@@ -168,11 +203,20 @@ void LtsSession::aboutToClose()
|
|||||||
aboutToCloseTab(LayoutArea::eSpecialTab);
|
aboutToCloseTab(LayoutArea::eSpecialTab);
|
||||||
aboutToCloseTab(LayoutArea::eMainTab);
|
aboutToCloseTab(LayoutArea::eMainTab);
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
void LtsSession::aboutToClose()
|
||||||
|
{
|
||||||
|
emit sessionAboutToBeDestroyed(this);
|
||||||
|
// no-op in non-RTI build
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
void LtsSession::slotStopWaitDialog()
|
void LtsSession::slotStopWaitDialog()
|
||||||
{
|
{
|
||||||
|
#ifdef BUILD_RTI
|
||||||
disconnect(this, &LtsSession::signalDoneInitializingSession, this, &LtsSession::slotStopWaitDialog);
|
disconnect(this, &LtsSession::signalDoneInitializingSession, this, &LtsSession::slotStopWaitDialog);
|
||||||
disconnect(this, &LtsSession::signalInitializationAborted, this, &LtsSession::slotStopWaitDialog);
|
disconnect(this, &LtsSession::signalInitializationAborted, this, &LtsSession::slotStopWaitDialog);
|
||||||
|
#endif
|
||||||
|
|
||||||
LtsWidgets::LtsGlobalWaitDialog::getInstance()->done();
|
LtsWidgets::LtsGlobalWaitDialog::getInstance()->done();
|
||||||
}
|
}
|
||||||
@@ -284,13 +328,16 @@ QIcon LtsSession::appToIcon(LtsAppDescriptor::App app)
|
|||||||
return LtsUtils::iconFromSvg(appIconFilename(app));
|
return LtsUtils::iconFromSvg(appIconFilename(app));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
bool LtsSession::removeMenuAction(LtsWidgets::LtsDragIcon* icon)
|
bool LtsSession::removeMenuAction(LtsWidgets::LtsDragIcon* icon)
|
||||||
{
|
{
|
||||||
if (!m_baseLayout)
|
if (!m_baseLayout)
|
||||||
return false;
|
return false;
|
||||||
return m_baseLayout->removeMenuAction(icon);
|
return m_baseLayout->removeMenuAction(icon);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::setMenuVisible(bool visible)
|
void LtsSession::setMenuVisible(bool visible)
|
||||||
{
|
{
|
||||||
m_menuVisible = visible;
|
m_menuVisible = visible;
|
||||||
@@ -300,7 +347,14 @@ void LtsSession::setMenuVisible(bool visible)
|
|||||||
|
|
||||||
m_baseLayout->getMenu()->setVisible(visible);
|
m_baseLayout->getMenu()->setVisible(visible);
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
void LtsSession::setMenuVisible(bool /*visible*/)
|
||||||
|
{
|
||||||
|
// no-op in non-RTI build
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
LtsDragIcon* LtsSession::addAction(const LtsWidgets::PluginData& plData, bool isFirstRun)
|
LtsDragIcon* LtsSession::addAction(const LtsWidgets::PluginData& plData, bool isFirstRun)
|
||||||
{
|
{
|
||||||
if (!m_baseLayout)
|
if (!m_baseLayout)
|
||||||
@@ -327,7 +381,21 @@ LtsNotification::LtsNotification* LtsSession::createNotification(const QString&
|
|||||||
|
|
||||||
return n;
|
return n;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
LtsDragIcon* LtsSession::addAction(const LtsWidgets::PluginData& /*plData*/, bool /*isFirstRun*/)
|
||||||
|
{
|
||||||
|
// no-op in non-RTI build
|
||||||
|
return nullptr;
|
||||||
|
}
|
||||||
|
|
||||||
|
LtsNotification::LtsNotification* LtsSession::createNotification(const QString& /*identifier*/)
|
||||||
|
{
|
||||||
|
// no-op in non-RTI build
|
||||||
|
return nullptr;
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
bool LtsSession::init(const DdsConnectionParams& connParams,
|
bool LtsSession::init(const DdsConnectionParams& connParams,
|
||||||
const QVector<LtsPluginManager::AppPluginInstance>& dataPluginList,
|
const QVector<LtsPluginManager::AppPluginInstance>& dataPluginList,
|
||||||
const QVector<LtsPluginManager::AppPluginInstance>& guiPluginList, bool hidden)
|
const QVector<LtsPluginManager::AppPluginInstance>& guiPluginList, bool hidden)
|
||||||
@@ -348,7 +416,9 @@ bool LtsSession::init(const dds::domain::DomainParticipant& dp, const DdsConnect
|
|||||||
initializePlugins(dataPluginList, guiPluginList);
|
initializePlugins(dataPluginList, guiPluginList);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::initializePlugins(const QVector<LtsPluginManager::AppPluginInstance>& dataPluginList,
|
void LtsSession::initializePlugins(const QVector<LtsPluginManager::AppPluginInstance>& dataPluginList,
|
||||||
const QVector<LtsPluginManager::AppPluginInstance>& guiPluginList)
|
const QVector<LtsPluginManager::AppPluginInstance>& guiPluginList)
|
||||||
{
|
{
|
||||||
@@ -410,7 +480,9 @@ void LtsSession::initializeDataPlugins(const QVector<LtsPluginManager::AppPlugin
|
|||||||
|
|
||||||
addAvailablaeDataPluginInterfaces(newDataPluginInterfaces);
|
addAvailablaeDataPluginInterfaces(newDataPluginInterfaces);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::initializeGuiPlugins(const QVector<LtsPluginManager::AppPluginInstance>& guiPluginList)
|
void LtsSession::initializeGuiPlugins(const QVector<LtsPluginManager::AppPluginInstance>& guiPluginList)
|
||||||
{
|
{
|
||||||
m_failedFetches.clear();
|
m_failedFetches.clear();
|
||||||
@@ -526,7 +598,9 @@ void LtsSession::initializeGuiPlugins(const QVector<LtsPluginManager::AppPluginI
|
|||||||
QTimer::singleShot(100, this, &LtsSession::slotStartPluginInit);
|
QTimer::singleShot(100, this, &LtsSession::slotStartPluginInit);
|
||||||
// executePayloads(); // does not execute when there are no payloads, but is needed to be called here !
|
// executePayloads(); // does not execute when there are no payloads, but is needed to be called here !
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
LtsTabWidget* LtsSession::locateWidget(QWidget* widgetToLocate, LayoutArea area)
|
LtsTabWidget* LtsSession::locateWidget(QWidget* widgetToLocate, LayoutArea area)
|
||||||
{
|
{
|
||||||
if (!m_baseLayout)
|
if (!m_baseLayout)
|
||||||
@@ -539,7 +613,14 @@ LtsTabWidget* LtsSession::locateWidget(QWidget* widgetToLocate, LayoutArea area)
|
|||||||
|
|
||||||
return nullptr; // not found!
|
return nullptr; // not found!
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
LtsTabWidget* LtsSession::locateWidget(QWidget* /*widgetToLocate*/, LayoutArea /*area*/)
|
||||||
|
{
|
||||||
|
return nullptr;
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::enableBaseLayoutMenu(bool on)
|
void LtsSession::enableBaseLayoutMenu(bool on)
|
||||||
{
|
{
|
||||||
if (m_baseLayout)
|
if (m_baseLayout)
|
||||||
@@ -560,6 +641,17 @@ void LtsSession::enableBaseLayoutArea(LtsWidgets::LayoutArea area, bool on)
|
|||||||
ltsWidget->setEnabled(on);
|
ltsWidget->setEnabled(on);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
void LtsSession::enableBaseLayoutMenu(bool /*on*/)
|
||||||
|
{
|
||||||
|
// no-op in non-RTI build
|
||||||
|
}
|
||||||
|
|
||||||
|
void LtsSession::enableBaseLayoutArea(LtsWidgets::LayoutArea /*area*/, bool /*on*/)
|
||||||
|
{
|
||||||
|
// no-op in non-RTI build
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
int LtsSession::workstationIp()
|
int LtsSession::workstationIp()
|
||||||
{
|
{
|
||||||
@@ -610,30 +702,41 @@ QString LtsSession::workstationName()
|
|||||||
|
|
||||||
const QString LtsSession::workspaceId() const
|
const QString LtsSession::workspaceId() const
|
||||||
{
|
{
|
||||||
|
#ifdef BUILD_RTI
|
||||||
if (isReplayPartition())
|
if (isReplayPartition())
|
||||||
return QStringLiteral("replay_%1").arg(QString::number(partitionId()));
|
return QStringLiteral("replay_%1").arg(QString::number(partitionId()));
|
||||||
|
#endif
|
||||||
return m_workspaceId; // sessionManager->workspaceId();
|
return m_workspaceId; // sessionManager->workspaceId();
|
||||||
}
|
}
|
||||||
|
|
||||||
void LtsSession::setWorkspaceId(const QString &newWorkspaceId /* <= MW: that's why I like "get" in getter names (needed to prepend "new" because of already existing method with the name "workspaceId") */)
|
void LtsSession::setWorkspaceId(const QString &newWorkspaceId /* <= MW: that's why I like "get" in getter names (needed to prepend "new" because of already existing method with the name "workspaceId") */)
|
||||||
{
|
{
|
||||||
|
#ifdef BUILD_RTI
|
||||||
DEBUG_LOG(m_logger) << LOGFUNCTION << " change workspaceId: cur = '" << m_workspaceId << "' for app '"
|
DEBUG_LOG(m_logger) << LOGFUNCTION << " change workspaceId: cur = '" << m_workspaceId << "' for app '"
|
||||||
<< appToString(app()) << "'";
|
<< appToString(app()) << "'";
|
||||||
DEBUG_LOG(m_logger) << LOGFUNCTION << " change workspaceId: new = '" << newWorkspaceId << "' for app '"
|
DEBUG_LOG(m_logger) << LOGFUNCTION << " change workspaceId: new = '" << newWorkspaceId << "' for app '"
|
||||||
<< appToString(app()) << "'";
|
<< appToString(app()) << "'";
|
||||||
|
#else
|
||||||
|
Q_UNUSED(newWorkspaceId)
|
||||||
|
#endif
|
||||||
m_workspaceId = newWorkspaceId; // m_sessionManager->setWorkspaceId(workspaceId);
|
m_workspaceId = newWorkspaceId; // m_sessionManager->setWorkspaceId(workspaceId);
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
if (m_baseLayout)
|
if (m_baseLayout)
|
||||||
m_baseLayout->setWorkspaceId(workspaceId() /* use getter instead of member var, as replay partition strings can only be retrieved with the getter */);
|
m_baseLayout->setWorkspaceId(workspaceId() /* use getter instead of member var, as replay partition strings can only be retrieved with the getter */);
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
emit workspaceIdChanged(newWorkspaceId);
|
emit workspaceIdChanged(newWorkspaceId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
ExcState LtsSession::exerciseState() const
|
ExcState LtsSession::exerciseState() const
|
||||||
{
|
{
|
||||||
return m_exerciseData ? m_exerciseData->exState : ExerciseState::eUnknown;
|
return m_exerciseData ? m_exerciseData->exState : ExerciseState::eUnknown;
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::connectOnlineHelpButton(LtsWidgets::LtsDialog* widget)
|
void LtsSession::connectOnlineHelpButton(LtsWidgets::LtsDialog* widget)
|
||||||
{
|
{
|
||||||
// FIXME: HACK: also connect show online help here !!
|
// FIXME: HACK: also connect show online help here !!
|
||||||
@@ -649,7 +752,6 @@ void LtsSession::slotStapleTopicLockHandler(LtsWidgets::LtsDialog* widget)
|
|||||||
}
|
}
|
||||||
widget->setProperty("topicLockStapled", true);
|
widget->setProperty("topicLockStapled", true);
|
||||||
|
|
||||||
#ifdef BUILD_RTI
|
|
||||||
connectOnlineHelpButton(widget);
|
connectOnlineHelpButton(widget);
|
||||||
if (m_coreFtc == nullptr)
|
if (m_coreFtc == nullptr)
|
||||||
{
|
{
|
||||||
@@ -684,12 +786,22 @@ void LtsSession::slotStapleTopicLockHandler(LtsWidgets::LtsDialog* widget)
|
|||||||
// qWarning() << "added tlh to" << widget->windowTitle();
|
// qWarning() << "added tlh to" << widget->windowTitle();
|
||||||
|
|
||||||
connectOnlineHelpButton(widget);
|
connectOnlineHelpButton(widget);
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
|
void LtsSession::connectOnlineHelpButton(LtsWidgets::LtsDialog* widget)
|
||||||
|
{
|
||||||
Q_UNUSED(widget)
|
Q_UNUSED(widget)
|
||||||
DEBUG_LOG(m_logger) << "BUILD_RTI=OFF, skipping TopicLockHandler setup";
|
// no-op in non-RTI build
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void LtsSession::slotStapleTopicLockHandler(LtsWidgets::LtsDialog* widget)
|
||||||
|
{
|
||||||
|
Q_UNUSED(widget)
|
||||||
|
// no-op in non-RTI build
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
bool LtsSession::focusTab(const QString& menuGroup, const QString& identifier, LtsWidgets::LayoutArea area)
|
bool LtsSession::focusTab(const QString& menuGroup, const QString& identifier, LtsWidgets::LayoutArea area)
|
||||||
{
|
{
|
||||||
if (!m_baseLayout)
|
if (!m_baseLayout)
|
||||||
@@ -700,7 +812,17 @@ bool LtsSession::focusTab(const QString& menuGroup, const QString& identifier, L
|
|||||||
|
|
||||||
return m_baseLayout->focusTab(menuGroup, identifier, area);
|
return m_baseLayout->focusTab(menuGroup, identifier, area);
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
bool LtsSession::focusTab(const QString& menuGroup, const QString& identifier, LtsWidgets::LayoutArea area)
|
||||||
|
{
|
||||||
|
Q_UNUSED(menuGroup)
|
||||||
|
Q_UNUSED(identifier)
|
||||||
|
Q_UNUSED(area)
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
LtsWidgets::LtsDialog* LtsSession::getWidget(const QString& menuGroup, const QString& identifier,
|
LtsWidgets::LtsDialog* LtsSession::getWidget(const QString& menuGroup, const QString& identifier,
|
||||||
LtsWidgets::LayoutArea area)
|
LtsWidgets::LayoutArea area)
|
||||||
{
|
{
|
||||||
@@ -713,7 +835,18 @@ LtsWidgets::LtsDialog* LtsSession::getWidget(const QString& menuGroup, const QSt
|
|||||||
|
|
||||||
return m_baseLayout->getWidget(menuGroup, identifier, area);
|
return m_baseLayout->getWidget(menuGroup, identifier, area);
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
LtsWidgets::LtsDialog* LtsSession::getWidget(const QString& menuGroup, const QString& identifier,
|
||||||
|
LtsWidgets::LayoutArea area)
|
||||||
|
{
|
||||||
|
Q_UNUSED(menuGroup)
|
||||||
|
Q_UNUSED(identifier)
|
||||||
|
Q_UNUSED(area)
|
||||||
|
return nullptr;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
bool LtsSession::widgetExists(const QString& menuGroup, const QString& identifier, LayoutArea area) const
|
bool LtsSession::widgetExists(const QString& menuGroup, const QString& identifier, LayoutArea area) const
|
||||||
{
|
{
|
||||||
if (!m_baseLayout)
|
if (!m_baseLayout)
|
||||||
@@ -724,7 +857,14 @@ bool LtsSession::widgetExists(const QString& menuGroup, const QString& identifie
|
|||||||
QWidget* existingWidget = tab->getWidget(menuGroup, identifier);
|
QWidget* existingWidget = tab->getWidget(menuGroup, identifier);
|
||||||
return existingWidget != nullptr;
|
return existingWidget != nullptr;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
bool LtsSession::widgetExists(const QString& /*menuGroup*/, const QString& /*identifier*/, LayoutArea /*area*/) const
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
bool LtsSession::addWidget(LtsDialog* widget, const QString& menuGroup, const QString& identifier, LayoutArea area,
|
bool LtsSession::addWidget(LtsDialog* widget, const QString& menuGroup, const QString& identifier, LayoutArea area,
|
||||||
bool setClosable)
|
bool setClosable)
|
||||||
{
|
{
|
||||||
@@ -739,12 +879,25 @@ bool LtsSession::addWidget(LtsDialog* widget, const QString& menuGroup, const QS
|
|||||||
// slotStapleTopicLockHandler(widget); => already done in blw's addWidget (below!)
|
// slotStapleTopicLockHandler(widget); => already done in blw's addWidget (below!)
|
||||||
// FIXMe: connect(widget, &LtsDialog::signalShowOnlineHelp,
|
// FIXMe: connect(widget, &LtsDialog::signalShowOnlineHelp,
|
||||||
// this, &LtsSession::slotShowOnlineHelp,
|
// this, &LtsSession::slotShowOnlineHelp,
|
||||||
// Qt::UniqueConnection); done in slotStaple.. because using LtsDialog::addDialog does NOT reach this
|
// Qt::UniqueConnection) done in slotStaple.. because using LtsDialog::addDialog does NOT reach this
|
||||||
// code here !
|
// code here !
|
||||||
|
|
||||||
return m_baseLayout->addWidget(widget, menuGroup, identifier, area, setClosable);
|
return m_baseLayout->addWidget(widget, menuGroup, identifier, area, setClosable);
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
bool LtsSession::addWidget(LtsDialog* widget, const QString& menuGroup, const QString& identifier, LayoutArea area,
|
||||||
|
bool setClosable)
|
||||||
|
{
|
||||||
|
Q_UNUSED(widget)
|
||||||
|
Q_UNUSED(menuGroup)
|
||||||
|
Q_UNUSED(identifier)
|
||||||
|
Q_UNUSED(area)
|
||||||
|
Q_UNUSED(setClosable)
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::setExerciseData(const LtsWidgets::ExerciseData& exerciseData)
|
void LtsSession::setExerciseData(const LtsWidgets::ExerciseData& exerciseData)
|
||||||
{
|
{
|
||||||
// avoid mutiple calls (and signal to emitted multiple times)
|
// avoid mutiple calls (and signal to emitted multiple times)
|
||||||
@@ -759,11 +912,6 @@ void LtsSession::setExerciseData(const LtsWidgets::ExerciseData& exerciseData)
|
|||||||
emit signalExerciseDataChanged();
|
emit signalExerciseDataChanged();
|
||||||
}
|
}
|
||||||
|
|
||||||
const LtsWidgets::ExerciseData* LtsSession::exerciseData() const
|
|
||||||
{
|
|
||||||
return m_exerciseData;
|
|
||||||
}
|
|
||||||
|
|
||||||
void LtsSession::setProfilePicture(const QPixmap& pixmap)
|
void LtsSession::setProfilePicture(const QPixmap& pixmap)
|
||||||
{
|
{
|
||||||
// partitionType(); ?!?
|
// partitionType(); ?!?
|
||||||
@@ -771,7 +919,9 @@ void LtsSession::setProfilePicture(const QPixmap& pixmap)
|
|||||||
return;
|
return;
|
||||||
m_baseLayout->setProfilePicture(pixmap);
|
m_baseLayout->setProfilePicture(pixmap);
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::makeVisible()
|
void LtsSession::makeVisible()
|
||||||
{
|
{
|
||||||
Q_ASSERT(m_baseLayout == nullptr);
|
Q_ASSERT(m_baseLayout == nullptr);
|
||||||
@@ -783,7 +933,14 @@ void LtsSession::makeVisible()
|
|||||||
|
|
||||||
createBaseLayout();
|
createBaseLayout();
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
void LtsSession::makeVisible()
|
||||||
|
{
|
||||||
|
// BUILD_RTI=OFF: No base layout to create
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::refetchActions()
|
void LtsSession::refetchActions()
|
||||||
{
|
{
|
||||||
// get actions
|
// get actions
|
||||||
@@ -853,12 +1010,27 @@ void LtsSession::refetchActions()
|
|||||||
|
|
||||||
m_firstActionsFetch = false;
|
m_firstActionsFetch = false;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
void LtsSession::refetchActions()
|
||||||
|
{
|
||||||
|
// BUILD_RTI=OFF: No actions to fetch
|
||||||
|
m_firstActionsFetch = false;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::slotSwap()
|
void LtsSession::slotSwap()
|
||||||
{
|
{
|
||||||
LtsMultiMonitor::LtsMultiMonitor::getInstance()->selectAndSwap(m_baseLayout);
|
LtsMultiMonitor::LtsMultiMonitor::getInstance()->selectAndSwap(m_baseLayout);
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
void LtsSession::slotSwap()
|
||||||
|
{
|
||||||
|
// BUILD_RTI=OFF: No base layout to swap
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
int LtsSession::screenId() const
|
int LtsSession::screenId() const
|
||||||
{
|
{
|
||||||
if (m_baseLayout == nullptr)
|
if (m_baseLayout == nullptr)
|
||||||
@@ -872,7 +1044,14 @@ int LtsSession::screenId() const
|
|||||||
|
|
||||||
return screen->screenId();
|
return screen->screenId();
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
int LtsSession::screenId() const
|
||||||
|
{
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
int LtsSession::screenContainerId() const
|
int LtsSession::screenContainerId() const
|
||||||
{
|
{
|
||||||
if (m_baseLayout == nullptr)
|
if (m_baseLayout == nullptr)
|
||||||
@@ -894,7 +1073,14 @@ int LtsSession::screenContainerId() const
|
|||||||
|
|
||||||
return -3;
|
return -3;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
int LtsSession::screenContainerId() const
|
||||||
|
{
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
int LtsSession::screenTypeId() const
|
int LtsSession::screenTypeId() const
|
||||||
{
|
{
|
||||||
if (m_baseLayout == nullptr)
|
if (m_baseLayout == nullptr)
|
||||||
@@ -908,12 +1094,26 @@ int LtsSession::screenTypeId() const
|
|||||||
|
|
||||||
return screen->screenType();
|
return screen->screenType();
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
int LtsSession::screenTypeId() const
|
||||||
|
{
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
LtsAppDescriptor::App LtsSession::app() const
|
LtsAppDescriptor::App LtsSession::app() const
|
||||||
{
|
{
|
||||||
return m_sessionManager ? m_sessionManager->appId() : LtsAppDescriptor::App::Login;
|
return m_sessionManager ? m_sessionManager->appId() : LtsAppDescriptor::App::Login;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
LtsAppDescriptor::App LtsSession::app() const
|
||||||
|
{
|
||||||
|
return LtsAppDescriptor::App::Login;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
bool LtsSession::event(QEvent* e)
|
bool LtsSession::event(QEvent* e)
|
||||||
{
|
{
|
||||||
if (e->type() == QEvent::LanguageChange)
|
if (e->type() == QEvent::LanguageChange)
|
||||||
@@ -921,7 +1121,15 @@ bool LtsSession::event(QEvent* e)
|
|||||||
|
|
||||||
return LtsSessionDataDds::event(e);
|
return LtsSessionDataDds::event(e);
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
bool LtsSession::event(QEvent* e)
|
||||||
|
{
|
||||||
|
Q_UNUSED(e)
|
||||||
|
return LtsSessionDataDds::event(e);
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::addDeveloperActions()
|
void LtsSession::addDeveloperActions()
|
||||||
{
|
{
|
||||||
// DEVELOPER / DEBUG MENU
|
// DEVELOPER / DEBUG MENU
|
||||||
@@ -992,7 +1200,9 @@ void LtsSession::addDeveloperActions()
|
|||||||
}
|
}
|
||||||
// END DEVELOPER / DEBUG MENU
|
// END DEVELOPER / DEBUG MENU
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
bool LtsSession::notifyUnsavedChanges()
|
bool LtsSession::notifyUnsavedChanges()
|
||||||
{
|
{
|
||||||
if (m_baseLayout == nullptr)
|
if (m_baseLayout == nullptr)
|
||||||
@@ -1000,7 +1210,14 @@ bool LtsSession::notifyUnsavedChanges()
|
|||||||
|
|
||||||
return m_baseLayout->notifyUnsavedChanges();
|
return m_baseLayout->notifyUnsavedChanges();
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
bool LtsSession::notifyUnsavedChanges()
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::createBaseLayout()
|
void LtsSession::createBaseLayout()
|
||||||
{
|
{
|
||||||
// qWarning() << "mep" <<
|
// qWarning() << "mep" <<
|
||||||
@@ -1154,7 +1371,9 @@ void LtsSession::createBaseLayout()
|
|||||||
|
|
||||||
emit hideAllOtherBLWs(this);
|
emit hideAllOtherBLWs(this);
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::slotMonitorSelected()
|
void LtsSession::slotMonitorSelected()
|
||||||
{
|
{
|
||||||
auto mmm = LtsMultiMonitor::LtsMultiMonitor::getInstance();
|
auto mmm = LtsMultiMonitor::LtsMultiMonitor::getInstance();
|
||||||
@@ -1182,7 +1401,9 @@ void LtsSession::slotMonitorSelected()
|
|||||||
emit signalScreenIdChanged(m_screenId, m_screenContainerId, screen->screenType());
|
emit signalScreenIdChanged(m_screenId, m_screenContainerId, screen->screenType());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::delayScriptEditorStart()
|
void LtsSession::delayScriptEditorStart()
|
||||||
{
|
{
|
||||||
DEBUG_LOG(m_logger) << "LtsSession::delayScriptEditorStart ";
|
DEBUG_LOG(m_logger) << "LtsSession::delayScriptEditorStart ";
|
||||||
@@ -1195,7 +1416,9 @@ void LtsSession::delayScriptEditorStart()
|
|||||||
// TRUE, it was not emitted before
|
// TRUE, it was not emitted before
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
bool LtsSession::isChildOfSession(QWidget* child)
|
bool LtsSession::isChildOfSession(QWidget* child)
|
||||||
{
|
{
|
||||||
if (!child)
|
if (!child)
|
||||||
@@ -1204,6 +1427,12 @@ bool LtsSession::isChildOfSession(QWidget* child)
|
|||||||
}
|
}
|
||||||
return baseLayout()->isAncestorOf(child);
|
return baseLayout()->isAncestorOf(child);
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
bool LtsSession::isChildOfSession(QWidget* /*child*/)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
void LtsSession::doneInitializingSession()
|
void LtsSession::doneInitializingSession()
|
||||||
{
|
{
|
||||||
@@ -1219,6 +1448,7 @@ void LtsSession::doneInitializingSession()
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
if (!m_sessionManager->isHeadless()) // disallow base layout creation if app is headless
|
if (!m_sessionManager->isHeadless()) // disallow base layout creation if app is headless
|
||||||
{
|
{
|
||||||
int sessionCount = m_sessionManager->sessionCount();
|
int sessionCount = m_sessionManager->sessionCount();
|
||||||
@@ -1234,7 +1464,9 @@ void LtsSession::doneInitializingSession()
|
|||||||
// return;
|
// return;
|
||||||
// }
|
// }
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
// qWarning() << "emit signalDoneInitializingSession();";
|
// qWarning() << "emit signalDoneInitializingSession();";
|
||||||
|
|
||||||
if (!createTopicClient<Core::Interface::Ftc>(m_coreFtc))
|
if (!createTopicClient<Core::Interface::Ftc>(m_coreFtc))
|
||||||
@@ -1258,10 +1490,15 @@ void LtsSession::doneInitializingSession()
|
|||||||
}
|
}
|
||||||
|
|
||||||
// qWarning() << "not headless !";
|
// qWarning() << "not headless !";
|
||||||
|
#else
|
||||||
|
// Non-RTI build: always emit signal after initialization
|
||||||
|
emit _signalDoneInitializingSession();
|
||||||
|
#endif // BUILD_RTI
|
||||||
}
|
}
|
||||||
|
|
||||||
void LtsSession::slotShowOnlineHelp(const QString& fileName)
|
void LtsSession::slotShowOnlineHelp(const QString& fileName)
|
||||||
{
|
{
|
||||||
|
#ifdef BUILD_RTI
|
||||||
if (m_ohvIfc == nullptr)
|
if (m_ohvIfc == nullptr)
|
||||||
{
|
{
|
||||||
LtsWidgets::LtsMessageDialog::showMessage(baseLayout() /* can be 0ptr */, tr("Online Help not available."));
|
LtsWidgets::LtsMessageDialog::showMessage(baseLayout() /* can be 0ptr */, tr("Online Help not available."));
|
||||||
@@ -1269,8 +1506,13 @@ void LtsSession::slotShowOnlineHelp(const QString& fileName)
|
|||||||
}
|
}
|
||||||
|
|
||||||
m_ohvIfc->showHelp(fileName);
|
m_ohvIfc->showHelp(fileName);
|
||||||
|
#else
|
||||||
|
Q_UNUSED(fileName)
|
||||||
|
// no-op in non-RTI build
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::slotShowOperatorSettings()
|
void LtsSession::slotShowOperatorSettings()
|
||||||
{
|
{
|
||||||
const QMap<LtsDragIcon*, PluginData>& mapButtons = m_baseLayout->mapButtons();
|
const QMap<LtsDragIcon*, PluginData>& mapButtons = m_baseLayout->mapButtons();
|
||||||
@@ -1297,7 +1539,9 @@ void LtsSession::slotShowOperatorSettings()
|
|||||||
|
|
||||||
WARNING_LOG(m_logger) << "action for showing operator settings not found !!";
|
WARNING_LOG(m_logger) << "action for showing operator settings not found !!";
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::slotStartPluginInit()
|
void LtsSession::slotStartPluginInit()
|
||||||
{
|
{
|
||||||
m_initializeThesePlugins = m_guiPluginInterfaces; // copy
|
m_initializeThesePlugins = m_guiPluginInterfaces; // copy
|
||||||
@@ -1377,7 +1621,9 @@ void LtsSession::slotPluginInitDone() // NEVER call this directly, queue a signa
|
|||||||
|
|
||||||
m_slotPluginInitDoneMutex = false; // unlock
|
m_slotPluginInitDoneMutex = false; // unlock
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::slotExecuteNextPayload()
|
void LtsSession::slotExecuteNextPayload()
|
||||||
{
|
{
|
||||||
LtsWidgets::LtsGlobalWaitDialog::getInstance()->wait(); // show wait dialog again
|
LtsWidgets::LtsGlobalWaitDialog::getInstance()->wait(); // show wait dialog again
|
||||||
@@ -1481,7 +1727,9 @@ void LtsSession::slotExecuteNextPayload()
|
|||||||
|
|
||||||
// m_ignoreSignalInLoop = false; // executing payload is done, clear the ignore-flag
|
// m_ignoreSignalInLoop = false; // executing payload is done, clear the ignore-flag
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::executePayloads()
|
void LtsSession::executePayloads()
|
||||||
{
|
{
|
||||||
// look for gui plugins (needed to get execution priority and run payloads)
|
// look for gui plugins (needed to get execution priority and run payloads)
|
||||||
@@ -1511,7 +1759,9 @@ void LtsSession::executePayloads()
|
|||||||
doneInitializingSession();
|
doneInitializingSession();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::clearDataPluginInterfaces()
|
void LtsSession::clearDataPluginInterfaces()
|
||||||
{
|
{
|
||||||
QMap<QString, std::weak_ptr<DataPluginBase::Interface>> weakDataPluginInterfaces;
|
QMap<QString, std::weak_ptr<DataPluginBase::Interface>> weakDataPluginInterfaces;
|
||||||
@@ -1540,7 +1790,9 @@ void LtsSession::clearDataPluginInterfaces()
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void LtsSession::clearGuiPluginInterfaces()
|
void LtsSession::clearGuiPluginInterfaces()
|
||||||
{
|
{
|
||||||
bool bInClearPluginInterfaces = true;
|
bool bInClearPluginInterfaces = true;
|
||||||
@@ -1581,10 +1833,13 @@ void LtsSession::clearGuiPluginInterfaces()
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
LtsSessionManager* LtsSession::getSessionManager()
|
LtsSessionManager* LtsSession::getSessionManager()
|
||||||
{
|
{
|
||||||
return m_sessionManager;
|
return m_sessionManager;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
} // namespace LtsSession
|
} // namespace LtsSession
|
||||||
+1822
File diff suppressed because it is too large.
Load diff
@@ -11,8 +11,11 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "lts_session_data_dds.h"
|
#include "lts_session_data_dds.h"
|
||||||
|
#ifdef BUILD_RTI
|
||||||
#include "lts_session_manager.h"
|
#include "lts_session_manager.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <LtsAppDescriptor/lts_app_descriptor.h>
|
||||||
#include <LtsSession/ltssession_export.h>
|
#include <LtsSession/ltssession_export.h>
|
||||||
#include <LtsWidgets/lts_base.h>
|
#include <LtsWidgets/lts_base.h>
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
@@ -83,12 +86,18 @@ class LTSSESSION_EXPORT LtsSession : public LtsSessionDataDds
|
|||||||
static QString appIconFilename(LtsAppDescriptor::App app);
|
static QString appIconFilename(LtsAppDescriptor::App app);
|
||||||
static QIcon appToIcon(LtsAppDescriptor::App app);
|
static QIcon appToIcon(LtsAppDescriptor::App app);
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
explicit LtsSession(LtsSessionManager* sessionManager);
|
explicit LtsSession(LtsSessionManager* sessionManager);
|
||||||
|
#else
|
||||||
|
explicit LtsSession();
|
||||||
|
#endif
|
||||||
~LtsSession();
|
~LtsSession();
|
||||||
|
|
||||||
QString toString() const;
|
QString toString() const;
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
LtsSessionManager* getSessionManager();
|
LtsSessionManager* getSessionManager();
|
||||||
|
#endif
|
||||||
bool init(const DdsConnectionParams& connParams, const QVector<LtsPluginManager::AppPluginInstance>& dataPluginList,
|
bool init(const DdsConnectionParams& connParams, const QVector<LtsPluginManager::AppPluginInstance>& dataPluginList,
|
||||||
const QVector<LtsPluginManager::AppPluginInstance>& guiPluginList, bool hidden);
|
const QVector<LtsPluginManager::AppPluginInstance>& guiPluginList, bool hidden);
|
||||||
#ifdef BUILD_RTI
|
#ifdef BUILD_RTI
|
||||||
@@ -96,7 +105,11 @@ class LTSSESSION_EXPORT LtsSession : public LtsSessionDataDds
|
|||||||
const QVector<LtsPluginManager::AppPluginInstance>& dataPluginList,
|
const QVector<LtsPluginManager::AppPluginInstance>& dataPluginList,
|
||||||
const QVector<LtsPluginManager::AppPluginInstance>& guiPluginList);
|
const QVector<LtsPluginManager::AppPluginInstance>& guiPluginList);
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void makeVisible();
|
void makeVisible();
|
||||||
|
#else
|
||||||
|
void makeVisible(); // no-op when BUILD_RTI=OFF
|
||||||
|
#endif
|
||||||
|
|
||||||
void setPayloadsEnabled()
|
void setPayloadsEnabled()
|
||||||
{
|
{
|
||||||
@@ -125,7 +138,9 @@ class LTSSESSION_EXPORT LtsSession : public LtsSessionDataDds
|
|||||||
*/
|
*/
|
||||||
LtsWidgets::LtsDragIcon* addAction(const LtsWidgets::PluginData& plData, bool isFirstRun = false);
|
LtsWidgets::LtsDragIcon* addAction(const LtsWidgets::PluginData& plData, bool isFirstRun = false);
|
||||||
void setMenuVisible(bool visible = true);
|
void setMenuVisible(bool visible = true);
|
||||||
|
#ifdef BUILD_RTI
|
||||||
bool removeMenuAction(LtsWidgets::LtsDragIcon* icon);
|
bool removeMenuAction(LtsWidgets::LtsDragIcon* icon);
|
||||||
|
#endif
|
||||||
int screenId() const;
|
int screenId() const;
|
||||||
int screenContainerId() const;
|
int screenContainerId() const;
|
||||||
int screenTypeId() const;
|
int screenTypeId() const;
|
||||||
@@ -153,9 +168,15 @@ class LTSSESSION_EXPORT LtsSession : public LtsSessionDataDds
|
|||||||
* and puts the text into all base layouts of this session
|
* and puts the text into all base layouts of this session
|
||||||
* @param exerciseData the human reable exercise name of the current exercise
|
* @param exerciseData the human reable exercise name of the current exercise
|
||||||
*/
|
*/
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void setExerciseData(const LtsWidgets::ExerciseData& exerciseData);
|
void setExerciseData(const LtsWidgets::ExerciseData& exerciseData);
|
||||||
const LtsWidgets::ExerciseData* exerciseData() const;
|
const LtsWidgets::ExerciseData* exerciseData() const;
|
||||||
void setProfilePicture(const QPixmap& pixmap);
|
void setProfilePicture(const QPixmap& pixmap);
|
||||||
|
#else
|
||||||
|
void setExerciseData(const LtsWidgets::ExerciseData& exerciseData) { Q_UNUSED(exerciseData) }
|
||||||
|
const LtsWidgets::ExerciseData* exerciseData() const { return nullptr; }
|
||||||
|
void setProfilePicture(const QPixmap& pixmap) { Q_UNUSED(pixmap) }
|
||||||
|
#endif
|
||||||
|
|
||||||
void setBaseLayoutVisible()
|
void setBaseLayoutVisible()
|
||||||
{
|
{
|
||||||
@@ -186,10 +207,14 @@ class LTSSESSION_EXPORT LtsSession : public LtsSessionDataDds
|
|||||||
*/
|
*/
|
||||||
bool isChildOfSession(QWidget* child);
|
bool isChildOfSession(QWidget* child);
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
LtsWidgets::LtsBaseLayoutWidget* baseLayout()
|
LtsWidgets::LtsBaseLayoutWidget* baseLayout()
|
||||||
{
|
{
|
||||||
return m_baseLayout;
|
return m_baseLayout;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
void* baseLayout() const { return nullptr; }
|
||||||
|
#endif
|
||||||
|
|
||||||
QWidget* baseLayoutWidget(); // prevents some classes to include LtsBaseLayoutWidget.h just to specify the blw as a
|
QWidget* baseLayoutWidget(); // prevents some classes to include LtsBaseLayoutWidget.h just to specify the blw as a
|
||||||
// parent widget
|
// parent widget
|
||||||
@@ -278,10 +303,14 @@ class LTSSESSION_EXPORT LtsSession : public LtsSessionDataDds
|
|||||||
m_hidden = true;
|
m_hidden = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
const QString workspaceId() const;
|
const QString workspaceId() const;
|
||||||
void setWorkspaceId(const QString& newWorkspaceId);
|
void setWorkspaceId(const QString& newWorkspaceId);
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
LtsWidgets::ExcState exerciseState() const;
|
LtsWidgets::ExcState exerciseState() const;
|
||||||
|
#else
|
||||||
|
LtsWidgets::ExcState exerciseState() const { return LtsWidgets::ExerciseState::eUnknown; }
|
||||||
|
#endif // BUILD_RTI
|
||||||
|
|
||||||
void setLoadedFromSavegame()
|
void setLoadedFromSavegame()
|
||||||
{
|
{
|
||||||
@@ -294,8 +323,24 @@ class LTSSESSION_EXPORT LtsSession : public LtsSessionDataDds
|
|||||||
}
|
}
|
||||||
|
|
||||||
void addDeveloperActions();
|
void addDeveloperActions();
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void refetchActions(); // Do not use.
|
void refetchActions(); // Do not use.
|
||||||
void setDependency(LtsSession* session);
|
#else
|
||||||
|
void refetchActions(); // Do not use. (no-op when BUILD_RTI=OFF)
|
||||||
|
#endif
|
||||||
|
void setDependency(LtsSession* session)
|
||||||
|
{
|
||||||
|
#ifdef BUILD_RTI
|
||||||
|
if (m_dependency)
|
||||||
|
{
|
||||||
|
ERROR_LOG(m_logger) << "Tried to set session dependency on self";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
m_dependency = session;
|
||||||
|
#else
|
||||||
|
Q_UNUSED(session)
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
bool hasDependency(LtsSession* session)
|
bool hasDependency(LtsSession* session)
|
||||||
{
|
{
|
||||||
@@ -320,19 +365,25 @@ class LTSSESSION_EXPORT LtsSession : public LtsSessionDataDds
|
|||||||
}
|
}
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void slotExecuteNextPayload(); // NEVER call this directly, queue a signal to this slot !
|
void slotExecuteNextPayload(); // NEVER call this directly, queue a signal to this slot !
|
||||||
void slotPluginInitDone(); // NEVER call this directly, queue a signal to this slot !
|
void slotPluginInitDone(); // NEVER call this directly, queue a signal to this slot !
|
||||||
|
#endif
|
||||||
void slotShowOnlineHelp(const QString& fileName);
|
void slotShowOnlineHelp(const QString& fileName);
|
||||||
// void takeOverBdv();
|
// void takeOverBdv();
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void slotShowOperatorSettings();
|
void slotShowOperatorSettings();
|
||||||
|
#endif
|
||||||
void slotSwap();
|
void slotSwap();
|
||||||
void slotStapleTopicLockHandler(LtsWidgets::LtsDialog* widget);
|
void slotStapleTopicLockHandler(LtsWidgets::LtsDialog* widget);
|
||||||
void slotStopWaitDialog();
|
void slotStopWaitDialog();
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void slotStartPluginInit();
|
void slotStartPluginInit();
|
||||||
void slotMonitorSelected();
|
void slotMonitorSelected();
|
||||||
void delayScriptEditorStart();
|
void delayScriptEditorStart();
|
||||||
|
#endif
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void signalInitializationAborted();
|
void signalInitializationAborted();
|
||||||
@@ -354,10 +405,13 @@ class LTSSESSION_EXPORT LtsSession : public LtsSessionDataDds
|
|||||||
private:
|
private:
|
||||||
friend class DeveloperTools::DevDialog;
|
friend class DeveloperTools::DevDialog;
|
||||||
friend class DeveloperTools::AppWidget;
|
friend class DeveloperTools::AppWidget;
|
||||||
|
#ifdef BUILD_RTI
|
||||||
friend class LtsSessionManager;
|
friend class LtsSessionManager;
|
||||||
|
#endif
|
||||||
|
|
||||||
bool event(QEvent* e) override;
|
bool event(QEvent* e) override;
|
||||||
void createBaseLayout();
|
void createBaseLayout();
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void initializePlugins(const QVector<LtsPluginManager::AppPluginInstance>& dataPluginList,
|
void initializePlugins(const QVector<LtsPluginManager::AppPluginInstance>& dataPluginList,
|
||||||
const QVector<LtsPluginManager::AppPluginInstance>& guiPluginList);
|
const QVector<LtsPluginManager::AppPluginInstance>& guiPluginList);
|
||||||
void initializeDataPlugins(const QVector<LtsPluginManager::AppPluginInstance>& dataPluginList);
|
void initializeDataPlugins(const QVector<LtsPluginManager::AppPluginInstance>& dataPluginList);
|
||||||
@@ -366,34 +420,51 @@ class LTSSESSION_EXPORT LtsSession : public LtsSessionDataDds
|
|||||||
void clearDataPluginInterfaces();
|
void clearDataPluginInterfaces();
|
||||||
void clearGuiPluginInterfaces();
|
void clearGuiPluginInterfaces();
|
||||||
void executePayloads();
|
void executePayloads();
|
||||||
|
#endif
|
||||||
void connectOnlineHelpButton(LtsWidgets::LtsDialog* widget);
|
void connectOnlineHelpButton(LtsWidgets::LtsDialog* widget);
|
||||||
// TODO: AFTER FAT !! void stapleWidget(LtsWidgets::LtsDialog *dialog); // FIXME: HACK: because an LtsDialog can
|
// TODO: AFTER FAT !! void stapleWidget(LtsWidgets::LtsDialog *dialog); // FIXME: HACK: because an LtsDialog can
|
||||||
// directly add widgets to the base layout and misses the staples...
|
// directly add widgets to the base layout and misses the staples...
|
||||||
void aboutToCloseTab(LtsWidgets::LayoutArea area);
|
void aboutToCloseTab(LtsWidgets::LayoutArea area);
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
QPointer<LtsSessionManager> m_sessionManager;
|
QPointer<LtsSessionManager> m_sessionManager;
|
||||||
|
#endif
|
||||||
|
#ifdef BUILD_RTI
|
||||||
QMap<int /*priority*/, std::shared_ptr<GuiPluginBase::Interface>>
|
QMap<int /*priority*/, std::shared_ptr<GuiPluginBase::Interface>>
|
||||||
m_payloadPriorityMap; // QMap automatically sorts by key on iteration and overwrites multiple occurences with
|
m_payloadPriorityMap; // QMap automatically sorts by key on iteration and overwrites multiple occurences with
|
||||||
// the latest)
|
// the latest)
|
||||||
QList<std::shared_ptr<GuiPluginBase::Interface>>
|
QList<std::shared_ptr<GuiPluginBase::Interface>>
|
||||||
m_payloadList; // for payloads that don't care when they are executed (prio '9999' plugins)
|
m_payloadList; // for payloads that don't care when they are executed (prio '9999' plugins)
|
||||||
|
#endif
|
||||||
LtsWidgets::LtsBackgroundWidget* m_mainBackground;
|
LtsWidgets::LtsBackgroundWidget* m_mainBackground;
|
||||||
bool m_hasBaseLayout;
|
bool m_hasBaseLayout;
|
||||||
|
#ifdef BUILD_RTI
|
||||||
LtsWidgets::LtsBaseLayoutWidget* m_baseLayout;
|
LtsWidgets::LtsBaseLayoutWidget* m_baseLayout;
|
||||||
|
#else
|
||||||
|
void* m_baseLayout{nullptr}; // stub for non-RTI build
|
||||||
|
#endif
|
||||||
bool m_markedForDeletion;
|
bool m_markedForDeletion;
|
||||||
bool m_payloads;
|
bool m_payloads;
|
||||||
QVector<LtsNotification::LtsNotificationController*> m_notiCtlList;
|
QVector<LtsNotification::LtsNotificationController*> m_notiCtlList;
|
||||||
bool m_initDone; // set by doneInitializingSession / signalDoneInitializingSession
|
bool m_initDone; // set by doneInitializingSession / signalDoneInitializingSession
|
||||||
|
#ifdef BUILD_RTI
|
||||||
bool m_payloadsDone{false}; // for debug
|
bool m_payloadsDone{false}; // for debug
|
||||||
|
#endif
|
||||||
bool m_menuVisible;
|
bool m_menuVisible;
|
||||||
// bool m_ignoreSignalInLoop = false;
|
// bool m_ignoreSignalInLoop = false;
|
||||||
bool m_firstActionsFetch;
|
bool m_firstActionsFetch;
|
||||||
|
#ifdef BUILD_RTI
|
||||||
LtsWidgets::ExerciseData* m_exerciseData;
|
LtsWidgets::ExerciseData* m_exerciseData;
|
||||||
|
#else
|
||||||
|
void* m_exerciseData{nullptr}; // stub for non-RTI build
|
||||||
|
#endif
|
||||||
QVector<LtsWidgets::PluginData> m_missingRightActions;
|
QVector<LtsWidgets::PluginData> m_missingRightActions;
|
||||||
std::shared_ptr<Core::Interface::Ftc> m_coreFtc;
|
std::shared_ptr<Core::Interface::Ftc> m_coreFtc;
|
||||||
|
#ifdef BUILD_RTI
|
||||||
GuiPluginBase::Interface* m_currentInitIfc; // not owning
|
GuiPluginBase::Interface* m_currentInitIfc; // not owning
|
||||||
bool m_slotPluginInitDoneMutex;
|
bool m_slotPluginInitDoneMutex;
|
||||||
bool m_pluginInitDone; // set by slotPluginInitDone
|
bool m_pluginInitDone; // set by slotPluginInitDone
|
||||||
|
#endif
|
||||||
QJsonObject m_savegame;
|
QJsonObject m_savegame;
|
||||||
bool m_hidden; // if true, does not create BLW
|
bool m_hidden; // if true, does not create BLW
|
||||||
int m_screenId{-1};
|
int m_screenId{-1};
|
||||||
@@ -403,7 +474,9 @@ class LTSSESSION_EXPORT LtsSession : public LtsSessionDataDds
|
|||||||
bool m_loadedFromSavegame;
|
bool m_loadedFromSavegame;
|
||||||
std::shared_ptr<OnlineHelp::ForeignOnlineHelpViewerGuiInterface> m_ohvIfc;
|
std::shared_ptr<OnlineHelp::ForeignOnlineHelpViewerGuiInterface> m_ohvIfc;
|
||||||
bool m_foreverInvisible; // if true, creates BLW but hides it and does not use MMM
|
bool m_foreverInvisible; // if true, creates BLW but hides it and does not use MMM
|
||||||
|
#ifdef BUILD_RTI
|
||||||
QStringList m_failedFetches;
|
QStringList m_failedFetches;
|
||||||
|
#endif
|
||||||
QVector<LtsWidgets::LtsBackgroundWidget*> m_bgWidgets;
|
QVector<LtsWidgets::LtsBackgroundWidget*> m_bgWidgets;
|
||||||
QString m_workspaceId;
|
QString m_workspaceId;
|
||||||
bool m_needsToBeSuccessfullyPlaced{
|
bool m_needsToBeSuccessfullyPlaced{
|
||||||
|
|||||||
@@ -0,0 +1,14 @@
|
|||||||
|
/**
|
||||||
|
* @RDE_HEADER@
|
||||||
|
* Stub implementation for lts_session_data_dds.cpp when BUILD_RTI=OFF
|
||||||
|
* Provides minimal implementations to allow linking without RTI Connext DDS
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "lts_session_data_dds_stub.h"
|
||||||
|
|
||||||
|
namespace LtsSession
|
||||||
|
{
|
||||||
|
|
||||||
|
// No additional implementation needed - all methods are inline in header
|
||||||
|
|
||||||
|
} // namespace LtsSession
|
||||||
@@ -2,12 +2,14 @@
|
|||||||
* @RDE_HEADER@
|
* @RDE_HEADER@
|
||||||
* Stub header for lts_session_data_dds.h when BUILD_RTI=OFF
|
* Stub header for lts_session_data_dds.h when BUILD_RTI=OFF
|
||||||
* Provides minimal declarations to allow compilation without RTI Connext DDS
|
* Provides minimal declarations to allow compilation without RTI Connext DDS
|
||||||
|
*
|
||||||
|
* NOTE: No Q_OBJECT macro - this is a stub class without signals/slots
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <QMap>
|
|
||||||
#include <QObject>
|
#include <QObject>
|
||||||
|
#include <QMap>
|
||||||
#include <QString>
|
#include <QString>
|
||||||
#include <QStringList>
|
#include <QStringList>
|
||||||
#include <QUrl>
|
#include <QUrl>
|
||||||
@@ -15,6 +17,9 @@
|
|||||||
|
|
||||||
#include "Lts/Common/ProjectConfig/project_defines.h"
|
#include "Lts/Common/ProjectConfig/project_defines.h"
|
||||||
|
|
||||||
|
// IDL::PartitionType is already defined in project_defines.h
|
||||||
|
// No need to redefine it here
|
||||||
|
|
||||||
namespace LtsSession
|
namespace LtsSession
|
||||||
{
|
{
|
||||||
|
|
||||||
@@ -72,13 +77,12 @@ namespace GuiPluginBase
|
|||||||
class Interface;
|
class Interface;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Stub LtsSessionDataDds class - minimal version without DDS functionality
|
// Stub LtsSessionDataDds class - inherits QObject for QPointer compatibility
|
||||||
|
// NO Q_OBJECT macro - avoids MOC generation issues, but provides QObject interface
|
||||||
class LtsSessionDataDds : public QObject
|
class LtsSessionDataDds : public QObject
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
|
||||||
public:
|
public:
|
||||||
explicit LtsSessionDataDds(QObject* parent = nullptr) : QObject(parent) {}
|
explicit LtsSessionDataDds(QObject* parent = nullptr) : QObject(parent) {}
|
||||||
|
|
||||||
~LtsSessionDataDds() override = default;
|
~LtsSessionDataDds() override = default;
|
||||||
|
|
||||||
bool init(const DdsConnectionParams&)
|
bool init(const DdsConnectionParams&)
|
||||||
@@ -136,16 +140,30 @@ class LtsSessionDataDds : public QObject
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
signals:
|
// Stub methods for signals (no-op in stub version)
|
||||||
void partitionTimeChanged(qint64);
|
void partitionTimeChanged(qint64) {} // no-op
|
||||||
void partitionTimeChangedInternal();
|
void partitionTimeChangedInternal() {} // no-op
|
||||||
|
|
||||||
|
// Q_OBJECT compatibility methods (delegate to QObject)
|
||||||
|
void* qt_metacast(const char* _clname) override
|
||||||
|
{
|
||||||
|
return QObject::qt_metacast(_clname);
|
||||||
|
}
|
||||||
|
int qt_metacall(QMetaObject::Call _c, int _id, void** _a) override
|
||||||
|
{
|
||||||
|
return QObject::qt_metacall(_c, _id, _a);
|
||||||
|
}
|
||||||
|
|
||||||
|
// staticMetaObject - inline definition to avoid linker errors
|
||||||
|
// Points to QObject's meta object since we have no custom meta-object
|
||||||
|
static inline const QMetaObject staticMetaObject = QObject::staticMetaObject;
|
||||||
};
|
};
|
||||||
|
|
||||||
// Stub Fetcher class
|
// Stub Fetcher class
|
||||||
class Fetcher
|
class Fetcher
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
Fetcher(LtsSessionDataDds*, const QString&) {}
|
Fetcher(LtsSession::LtsSessionDataDds*, const QString&) {}
|
||||||
|
|
||||||
template <typename T> void getForeignGuiInterface(std::shared_ptr<T>&, const QString&, bool) {}
|
template <typename T> void getForeignGuiInterface(std::shared_ptr<T>&, const QString&, bool) {}
|
||||||
|
|
||||||
|
|||||||
@@ -10,6 +10,8 @@
|
|||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
|
|
||||||
#include <Lts/Common/ProjectConfig/project_defines.h>
|
#include <Lts/Common/ProjectConfig/project_defines.h>
|
||||||
#include <LtsPluginManager/lts_plugin_loader.h>
|
#include <LtsPluginManager/lts_plugin_loader.h>
|
||||||
#include <LtsPluginManager/lts_plugin_manager.h>
|
#include <LtsPluginManager/lts_plugin_manager.h>
|
||||||
@@ -120,3 +122,5 @@ class LTSSESSION_EXPORT LtsSessionManager : public QObject
|
|||||||
};
|
};
|
||||||
|
|
||||||
} // namespace LtsSession
|
} // namespace LtsSession
|
||||||
|
|
||||||
|
#endif // BUILD_RTI
|
||||||
+2
-2
@@ -43,12 +43,12 @@ NGL_TARGET_INCLUDE_DIRECTORIES(LtsUtilsDds
|
|||||||
${CMAKE_CURRENT_SOURCE_DIR}/../
|
${CMAKE_CURRENT_SOURCE_DIR}/../
|
||||||
${CMAKE_CURRENT_BINARY_DIR}/../
|
${CMAKE_CURRENT_BINARY_DIR}/../
|
||||||
)
|
)
|
||||||
IF(BUILD_RTI)
|
|
||||||
NGL_TARGET_LINK_LIBRARIES(LtsUtilsDds
|
NGL_TARGET_LINK_LIBRARIES(LtsUtilsDds
|
||||||
PRIVATE
|
PRIVATE
|
||||||
LtsUtilsCoreHeaderOnly
|
LtsUtilsCoreHeaderOnly
|
||||||
PUBLIC
|
PUBLIC
|
||||||
Qt6::Core
|
Qt6::Core
|
||||||
ddscore
|
|
||||||
)
|
)
|
||||||
|
IF(BUILD_RTI)
|
||||||
|
TARGET_LINK_LIBRARIES(LtsUtilsDds PUBLIC ddscore)
|
||||||
ENDIF(BUILD_RTI)
|
ENDIF(BUILD_RTI)
|
||||||
@@ -11,7 +11,8 @@ namespace LtsWebSocket
|
|||||||
{
|
{
|
||||||
|
|
||||||
LtsWebSocketServer::LtsWebSocketServer(AbstractClientMessageFactory* messageFactory, QObject* parent)
|
LtsWebSocketServer::LtsWebSocketServer(AbstractClientMessageFactory* messageFactory, QObject* parent)
|
||||||
: QObject(parent), m_logger(getLogger("LtsWebSocket.Server")), m_queueTimer(new QTimer(this)), m_messageFactory(messageFactory), m_connectionHandler(nullptr)
|
: QObject(parent), m_queueTimer(new QTimer(this)), m_messageFactory(messageFactory), m_connectionHandler(nullptr),
|
||||||
|
m_logger(getLogger("LtsWebSocket.Server"))
|
||||||
{
|
{
|
||||||
connect(m_queueTimer, &QTimer::timeout, this, &LtsWebSocketServer::onQueueTimerTimeout);
|
connect(m_queueTimer, &QTimer::timeout, this, &LtsWebSocketServer::onQueueTimerTimeout);
|
||||||
|
|
||||||
|
|||||||
@@ -17,6 +17,7 @@ ADD_INTERFACE_LIBRARY(AsbDataPluginInterface
|
|||||||
${CMAKE_CURRENT_SOURCE_DIR}/..
|
${CMAKE_CURRENT_SOURCE_DIR}/..
|
||||||
DataPluginInterface
|
DataPluginInterface
|
||||||
advancedSymbology
|
advancedSymbology
|
||||||
|
Qt6::Gui
|
||||||
)
|
)
|
||||||
|
|
||||||
#
|
#
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
#include "logger.h"
|
#include "logger.h"
|
||||||
|
|
||||||
#include <NGLLogger/NGLLoggerBootstrap.h>
|
#include <NGLLoggerBootstrap.h>
|
||||||
|
|
||||||
namespace BuildingViewer
|
namespace BuildingViewer
|
||||||
{
|
{
|
||||||
|
|||||||
+1
-1
@@ -4,7 +4,7 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <QColor>
|
#include <QColor>
|
||||||
#include <Symbology/symbol_dictionary.h>
|
#include <Lts/Viewer/SituationMap/Symbology/symbol_dictionary.h>
|
||||||
#include <PluginInterfaces/data_plugin_interface.h>
|
#include <PluginInterfaces/data_plugin_interface.h>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+2
-1
@@ -54,11 +54,12 @@ class GetExerciseImageRequester : public AbstractRequester,
|
|||||||
GetExerciseImageReply m_reply;
|
GetExerciseImageReply m_reply;
|
||||||
};
|
};
|
||||||
|
|
||||||
class ExerciseManagementDialogModel final : public LtsWidgets::LtsAbstractTableModel<ExerciseManagement::Exercise>
|
class ExerciseManagementDialogModel final : public LtsWidgets::LtsAbstractTableModel<Exercise>
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
using Exercise = ExerciseManagement::Exercise;
|
||||||
enum Columns {
|
enum Columns {
|
||||||
Id,
|
Id,
|
||||||
Name,
|
Name,
|
||||||
|
|||||||
+1
-1
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <FileManagement/flm_enums.hpp>
|
#include <Lts/Plugins/FileManagement/flm_enums.hpp>
|
||||||
#include <FileManagement/flm_dtc.h>
|
#include <FileManagement/flm_dtc.h>
|
||||||
#include <PluginInterfaces/topic_replay_interface.h>
|
#include <PluginInterfaces/topic_replay_interface.h>
|
||||||
#include <TopicEditorBase/topic_editor_interface.h>
|
#include <TopicEditorBase/topic_editor_interface.h>
|
||||||
|
|||||||
@@ -18,7 +18,9 @@ SET(gna_common_gui_SRCS
|
|||||||
NGL_ADD_LIBRARY2(WS GnaCommon SHARED ${gna_common_gui_SRCS} )
|
NGL_ADD_LIBRARY2(WS GnaCommon SHARED ${gna_common_gui_SRCS} )
|
||||||
NGL_TARGET_INCLUDE_DIRECTORIES(GnaCommon
|
NGL_TARGET_INCLUDE_DIRECTORIES(GnaCommon
|
||||||
PUBLIC
|
PUBLIC
|
||||||
|
${CMAKE_CURRENT_SOURCE_DIR}/../../
|
||||||
${CMAKE_CURRENT_SOURCE_DIR}/../../Services/
|
${CMAKE_CURRENT_SOURCE_DIR}/../../Services/
|
||||||
|
${CMAKE_CURRENT_SOURCE_DIR}/../../../../Proxies/
|
||||||
)
|
)
|
||||||
NGL_TARGET_LINK_LIBRARIES(GnaCommon
|
NGL_TARGET_LINK_LIBRARIES(GnaCommon
|
||||||
PRIVATE
|
PRIVATE
|
||||||
|
|||||||
+1
-1
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
#include "gnacommon_export.h"
|
#include "gnacommon_export.h"
|
||||||
#include <GuezNasat/gna_dtc.h>
|
#include <GuezNasat/gna_dtc.h>
|
||||||
#include <LtsGuezNasat/logger.h>
|
#include <GuezNasat/logger.h>
|
||||||
|
|
||||||
#include <LtsWidgets/lts_abstract_table_model.h>
|
#include <LtsWidgets/lts_abstract_table_model.h>
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -9,7 +9,7 @@
|
|||||||
#include <ExerciseManagement/exm_dtc.h>
|
#include <ExerciseManagement/exm_dtc.h>
|
||||||
|
|
||||||
#include <ParticipantManagement/ppm.hpp>
|
#include <ParticipantManagement/ppm.hpp>
|
||||||
#include <ParticipantManagement/ppm_gui_combobox_plugin_interface.h>
|
#include <Lts/Plugins/ParticipantManagement/ppm_gui_combobox_plugin_interface.h>
|
||||||
|
|
||||||
#include <GuezNasat/logger.h>
|
#include <GuezNasat/logger.h>
|
||||||
|
|
||||||
|
|||||||
+13
-3
@@ -11,12 +11,18 @@
|
|||||||
SET(mrk_common_gui_SRCS
|
SET(mrk_common_gui_SRCS
|
||||||
mrk_dialog_model.cpp
|
mrk_dialog_model.cpp
|
||||||
mrk_dialog_model.h
|
mrk_dialog_model.h
|
||||||
mrk_apply_filter.cpp
|
|
||||||
mrk_apply_filter.h
|
|
||||||
CustomViews/mrk_marker.cpp
|
CustomViews/mrk_marker.cpp
|
||||||
CustomViews/mrk_marker.h
|
CustomViews/mrk_marker.h
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# FilterManagement-Plugins temporär ausgeschlossen für BUILD_RTI=OFF
|
||||||
|
# if(BUILD_RTI)
|
||||||
|
# list(APPEND mrk_common_gui_SRCS
|
||||||
|
# mrk_apply_filter.cpp
|
||||||
|
# mrk_apply_filter.h
|
||||||
|
# )
|
||||||
|
# endif()
|
||||||
|
|
||||||
NGL_WRAP_UI(mrk_common_gui_SRCS
|
NGL_WRAP_UI(mrk_common_gui_SRCS
|
||||||
CustomViews/mrk_marker.ui
|
CustomViews/mrk_marker.ui
|
||||||
)
|
)
|
||||||
@@ -33,7 +39,6 @@ NGL_TARGET_LINK_LIBRARIES(MrkCommon
|
|||||||
LtsSessionData
|
LtsSessionData
|
||||||
LtsUtilsGuiDds
|
LtsUtilsGuiDds
|
||||||
OpmDataPluginInterface
|
OpmDataPluginInterface
|
||||||
FltDataPluginInterface
|
|
||||||
ngltools
|
ngltools
|
||||||
PUBLIC
|
PUBLIC
|
||||||
MrkDataPluginInterface
|
MrkDataPluginInterface
|
||||||
@@ -41,3 +46,8 @@ NGL_TARGET_LINK_LIBRARIES(MrkCommon
|
|||||||
LtsWidgets
|
LtsWidgets
|
||||||
LtsDataView
|
LtsDataView
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# FilterManagement nur bei BUILD_RTI
|
||||||
|
if(BUILD_RTI)
|
||||||
|
target_link_libraries(MrkCommon PRIVATE FltDataPluginInterface)
|
||||||
|
endif()
|
||||||
+1
-1
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <LtsDataView/abstract_display_widget.h>
|
#include <abstract_display_widget.h>
|
||||||
#include <mrkcommon_export.h>
|
#include <mrkcommon_export.h>
|
||||||
|
|
||||||
namespace Ui
|
namespace Ui
|
||||||
|
|||||||
-1
@@ -5,7 +5,6 @@
|
|||||||
|
|
||||||
#include "mrk_dialog_model.h"
|
#include "mrk_dialog_model.h"
|
||||||
#include <utility>
|
#include <utility>
|
||||||
#include <MarkerManagement/mrk_translation.h>
|
|
||||||
#include <OperatorManagement/opm_dtc.h>
|
#include <OperatorManagement/opm_dtc.h>
|
||||||
|
|
||||||
#include <ngltools/ngltools_dtg.h>
|
#include <ngltools/ngltools_dtg.h>
|
||||||
|
|||||||
+2
-1
@@ -12,11 +12,12 @@
|
|||||||
namespace OcBaseDownload
|
namespace OcBaseDownload
|
||||||
{
|
{
|
||||||
|
|
||||||
class ExModel final : public LtsWidgets::LtsAbstractTableModel<ExerciseManagement::Exercise>
|
class ExModel final : public LtsWidgets::LtsAbstractTableModel<Exercise>
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
using Exercise = ExerciseManagement::Exercise;
|
||||||
enum Columns
|
enum Columns
|
||||||
{
|
{
|
||||||
Name,
|
Name,
|
||||||
|
|||||||
@@ -5,6 +5,7 @@
|
|||||||
# Created by Christian Ehrlicher, SLSE, 2016-03-01
|
# Created by Christian Ehrlicher, SLSE, 2016-03-01
|
||||||
#
|
#
|
||||||
|
|
||||||
|
IF(BUILD_RTI)
|
||||||
ADD_SUBDIRECTORY(Data)
|
ADD_SUBDIRECTORY(Data)
|
||||||
ADD_SUBDIRECTORY(Gui)
|
ADD_SUBDIRECTORY(Gui)
|
||||||
|
|
||||||
@@ -54,3 +55,4 @@ ADD_INTERFACE_LIBRARY(OpmDataPluginInterface
|
|||||||
DataPluginInterface
|
DataPluginInterface
|
||||||
svcOpmCommon
|
svcOpmCommon
|
||||||
)
|
)
|
||||||
|
ENDIF()
|
||||||
@@ -5,10 +5,12 @@
|
|||||||
# Created by Christian Ehrlicher, SLSE, 2016-02-29
|
# Created by Christian Ehrlicher, SLSE, 2016-02-29
|
||||||
#
|
#
|
||||||
|
|
||||||
|
IF(BUILD_RTI)
|
||||||
ADD_SUBDIRECTORY(Common)
|
ADD_SUBDIRECTORY(Common)
|
||||||
ADD_SUBDIRECTORY(OperatorOverview)
|
ADD_SUBDIRECTORY(OperatorOverview)
|
||||||
ADD_SUBDIRECTORY(OperatorSettings)
|
ADD_SUBDIRECTORY(OperatorSettings)
|
||||||
ADD_SUBDIRECTORY(OperatorEdit)
|
ADD_SUBDIRECTORY(OperatorEdit)
|
||||||
ADD_SUBDIRECTORY(Login)
|
ADD_SUBDIRECTORY(Login)
|
||||||
ADD_SUBDIRECTORY(OpmComboBox)
|
ADD_SUBDIRECTORY(OpmComboBox)
|
||||||
|
ENDIF()
|
||||||
#ADD_SUBDIRECTORY(NewLogin)
|
#ADD_SUBDIRECTORY(NewLogin)
|
||||||
+18
-5
@@ -4,6 +4,8 @@
|
|||||||
|
|
||||||
#include "operator_dialog_model.h"
|
#include "operator_dialog_model.h"
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
|
|
||||||
#include <ngltools/ngltools_dtg.h>
|
#include <ngltools/ngltools_dtg.h>
|
||||||
#include <ParticipantManagement/ppm_data_plugin_interface.h>
|
#include <ParticipantManagement/ppm_data_plugin_interface.h>
|
||||||
#include <ParticipantManagement/ppm_translation.h>
|
#include <ParticipantManagement/ppm_translation.h>
|
||||||
@@ -19,7 +21,7 @@ namespace OperatorManagement
|
|||||||
|
|
||||||
|
|
||||||
OperatorManagementDialogModel::OperatorManagementDialogModel(QObject *parent, int exerciseId )
|
OperatorManagementDialogModel::OperatorManagementDialogModel(QObject *parent, int exerciseId )
|
||||||
: LtsWidgets::LtsAbstractTableModel<OperatorManagement::User>({tr("Id"),
|
: LtsWidgets::LtsAbstractTableModel<UserType>({tr("Id"),
|
||||||
tr("Name"),
|
tr("Name"),
|
||||||
tr("Info"),
|
tr("Info"),
|
||||||
tr("Effective ACLs"),
|
tr("Effective ACLs"),
|
||||||
@@ -34,7 +36,9 @@ OperatorManagementDialogModel::OperatorManagementDialogModel(QObject *parent, in
|
|||||||
parent)
|
parent)
|
||||||
, m_dtc(nullptr)
|
, m_dtc(nullptr)
|
||||||
, m_ppmDtc(nullptr)
|
, m_ppmDtc(nullptr)
|
||||||
|
#ifdef BUILD_RTI
|
||||||
, m_exmDtc(nullptr)
|
, m_exmDtc(nullptr)
|
||||||
|
#endif
|
||||||
, m_exerciseId(exerciseId)
|
, m_exerciseId(exerciseId)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
@@ -45,11 +49,13 @@ bool OperatorManagementDialogModel::initModel(LtsSession::LtsSession *session, c
|
|||||||
{
|
{
|
||||||
m_dtc = dtc;
|
m_dtc = dtc;
|
||||||
session->getDtc<ParticipantManagement::DataInterface>(m_ppmDtc);
|
session->getDtc<ParticipantManagement::DataInterface>(m_ppmDtc);
|
||||||
|
#ifdef BUILD_RTI
|
||||||
session->getDtc<ExerciseManagement::DataInterface>(m_exmDtc);
|
session->getDtc<ExerciseManagement::DataInterface>(m_exmDtc);
|
||||||
|
#endif
|
||||||
|
|
||||||
connect(m_dtc.get(), &OperatorManagement::Interface::Dtc::userChanged,
|
connect(m_dtc.get(), &OperatorManagement::Interface::Dtc::userChanged,
|
||||||
this, &OperatorManagementDialogModel::onDataChanged);
|
this, &OperatorManagementDialogModel::onDataChanged);
|
||||||
m_dtc->users([this](const OperatorManagement::User &op) { insertRow(op); });
|
m_dtc->users([this](const UserType &op) { insertRow(op); });
|
||||||
|
|
||||||
if (m_ppmDtc)
|
if (m_ppmDtc)
|
||||||
{
|
{
|
||||||
@@ -66,6 +72,7 @@ bool OperatorManagementDialogModel::initModel(LtsSession::LtsSession *session, c
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
if (m_exmDtc)
|
if (m_exmDtc)
|
||||||
{
|
{
|
||||||
connect(m_exmDtc.get(), &ExerciseManagement::Interface::Dtc::exerciseChanged,
|
connect(m_exmDtc.get(), &ExerciseManagement::Interface::Dtc::exerciseChanged,
|
||||||
@@ -80,6 +87,7 @@ bool OperatorManagementDialogModel::initModel(LtsSession::LtsSession *session, c
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
{
|
{
|
||||||
auto cb = [this](const Group &group)
|
auto cb = [this](const Group &group)
|
||||||
@@ -106,6 +114,7 @@ void OperatorManagementDialogModel::onPartyChanged(const ParticipantManagement::
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
void OperatorManagementDialogModel::onExerciseChanged(const ExerciseManagement::Exercise &data, DataModification modType)
|
void OperatorManagementDialogModel::onExerciseChanged(const ExerciseManagement::Exercise &data, DataModification modType)
|
||||||
{
|
{
|
||||||
if (modType == DataModification::eRemoved)
|
if (modType == DataModification::eRemoved)
|
||||||
@@ -118,6 +127,7 @@ void OperatorManagementDialogModel::onExerciseChanged(const ExerciseManagement::
|
|||||||
emit dataChanged(idx, idx);
|
emit dataChanged(idx, idx);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
QVariant OperatorManagementDialogModel::data(const QModelIndex &index, int role) const
|
QVariant OperatorManagementDialogModel::data(const QModelIndex &index, int role) const
|
||||||
{
|
{
|
||||||
@@ -132,7 +142,7 @@ QVariant OperatorManagementDialogModel::data(const QModelIndex &index, int role)
|
|||||||
|
|
||||||
if (role == Qt::DisplayRole)
|
if (role == Qt::DisplayRole)
|
||||||
{
|
{
|
||||||
const OperatorManagement::User &op = m_vecData.at(index.row());
|
const UserType &op = m_vecData.at(index.row());
|
||||||
std::vector<OperatorManagement::PartiesByExercise> pbe = op.visiblePartiesByExercise();
|
std::vector<OperatorManagement::PartiesByExercise> pbe = op.visiblePartiesByExercise();
|
||||||
switch (index.column())
|
switch (index.column())
|
||||||
{
|
{
|
||||||
@@ -240,7 +250,7 @@ QString OperatorManagementDialogModel::visibleParties(const std::vector<int32_t>
|
|||||||
return result.join(QStringLiteral(", "));
|
return result.join(QStringLiteral(", "));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
QString OperatorManagementDialogModel::exercises(const std::vector<int32_t> &exercises) const
|
QString OperatorManagementDialogModel::exercises(const std::vector<int32_t> &exercises) const
|
||||||
{
|
{
|
||||||
QStringList result;
|
QStringList result;
|
||||||
@@ -250,6 +260,7 @@ QString OperatorManagementDialogModel::exercises(const std::vector<int32_t> &exe
|
|||||||
|
|
||||||
return result.join(QStringLiteral(", "));
|
return result.join(QStringLiteral(", "));
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
QString OperatorManagementDialogModel::effectiveAcls(std::vector<int32_t> acls) const
|
QString OperatorManagementDialogModel::effectiveAcls(std::vector<int32_t> acls) const
|
||||||
{
|
{
|
||||||
@@ -267,7 +278,7 @@ QString OperatorManagementDialogModel::priority(int16_t prio) const
|
|||||||
return QString::number(prio);
|
return QString::number(prio);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool OperatorManagementDialogModel::isFiltered(const OperatorManagement::User &data, DataModification modType) const
|
bool OperatorManagementDialogModel::isFiltered(const UserType &data, DataModification modType) const
|
||||||
{
|
{
|
||||||
Q_UNUSED(modType);
|
Q_UNUSED(modType);
|
||||||
|
|
||||||
@@ -281,3 +292,5 @@ bool OperatorManagementDialogModel::isFiltered(const OperatorManagement::User &d
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif // BUILD_RTI
|
||||||
+9
-4
@@ -3,6 +3,8 @@
|
|||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
|
|
||||||
#include <OperatorManagement/opm_dtc.h>
|
#include <OperatorManagement/opm_dtc.h>
|
||||||
#include <ParticipantManagement/ppm.hpp>
|
#include <ParticipantManagement/ppm.hpp>
|
||||||
#include <ExerciseManagement/exm_dtc.h>
|
#include <ExerciseManagement/exm_dtc.h>
|
||||||
@@ -15,9 +17,10 @@
|
|||||||
namespace OperatorManagement
|
namespace OperatorManagement
|
||||||
{
|
{
|
||||||
|
|
||||||
|
// Typ-Alias um Namespace-Konflikt mit QtMocConstants::User zu vermeiden
|
||||||
|
using UserType = User;
|
||||||
|
|
||||||
|
class OPMCHANGEPASSWORDGUI_EXPORT OperatorManagementDialogModel final : public LtsWidgets::LtsAbstractTableModel<UserType>
|
||||||
class OPMCHANGEPASSWORDGUI_EXPORT OperatorManagementDialogModel final : public LtsWidgets::LtsAbstractTableModel<OperatorManagement::User>
|
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
@@ -42,9 +45,9 @@ public:
|
|||||||
|
|
||||||
bool initModel(LtsSession::LtsSession *session, const std::shared_ptr<OperatorManagement::Interface::Dtc> &dtc);
|
bool initModel(LtsSession::LtsSession *session, const std::shared_ptr<OperatorManagement::Interface::Dtc> &dtc);
|
||||||
|
|
||||||
QVariant data(const QModelIndex &, int) const override final;
|
QVariant data(const QModelIndex &, int) const override;
|
||||||
|
|
||||||
bool isFiltered( const OperatorManagement::User &data, DataModification modType ) const override;
|
bool isFiltered( const UserType &data, DataModification modType ) const override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
@@ -72,3 +75,5 @@ private:
|
|||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif // BUILD_RTI
|
||||||
+2
-2
@@ -221,11 +221,11 @@ bool fill(QComboBox *cbx, PdmComboBoxType type)
|
|||||||
case PdmComboBoxType::CbLanguage:
|
case PdmComboBoxType::CbLanguage:
|
||||||
{
|
{
|
||||||
const QString languages = LtsUtils::ProjectSettings::getInstance()->value(QStringLiteral("pdm"), QStringLiteral("EquipmentLanguages")).toString();
|
const QString languages = LtsUtils::ProjectSettings::getInstance()->value(QStringLiteral("pdm"), QStringLiteral("EquipmentLanguages")).toString();
|
||||||
const QVector<QStringRef> slLang = languages.splitRef(QLatin1Char(','));
|
const QStringList slLang = languages.split(QLatin1Char(','));
|
||||||
QSet<int> alreadySeen;
|
QSet<int> alreadySeen;
|
||||||
alreadySeen += LanguageConfiguration::NoChange;
|
alreadySeen += LanguageConfiguration::NoChange;
|
||||||
cbx->addItem(toString(LanguageConfiguration::NoChange), LanguageConfiguration::NoChange);
|
cbx->addItem(toString(LanguageConfiguration::NoChange), LanguageConfiguration::NoChange);
|
||||||
for (const QStringRef &r : slLang)
|
for (const QString &r : slLang)
|
||||||
{
|
{
|
||||||
const int langId = r.toInt();
|
const int langId = r.toInt();
|
||||||
if (alreadySeen.contains(langId))
|
if (alreadySeen.contains(langId))
|
||||||
|
|||||||
+1
@@ -6,6 +6,7 @@
|
|||||||
|
|
||||||
#include <QSortFilterProxyModel>
|
#include <QSortFilterProxyModel>
|
||||||
#include <ProjectDataManagement/pdm_dtc.h>
|
#include <ProjectDataManagement/pdm_dtc.h>
|
||||||
|
#include <Lts/Proxies/TrainingAreaBase/training_area_telegrams.h>
|
||||||
|
|
||||||
class QComboBox;
|
class QComboBox;
|
||||||
class QStandardItemModel;
|
class QStandardItemModel;
|
||||||
|
|||||||
@@ -5,6 +5,8 @@
|
|||||||
# Created by Christian Ehrlicher, SLSE, 2016-03-01
|
# Created by Christian Ehrlicher, SLSE, 2016-03-01
|
||||||
#
|
#
|
||||||
|
|
||||||
|
IF(BUILD_RTI)
|
||||||
|
|
||||||
ADD_SUBDIRECTORY(Gui)
|
ADD_SUBDIRECTORY(Gui)
|
||||||
|
|
||||||
#
|
#
|
||||||
@@ -24,3 +26,5 @@ ADD_INTERFACE_LIBRARY(SituationMapScriptFilterGuiPluginInterface
|
|||||||
${CMAKE_CURRENT_SOURCE_DIR}/..
|
${CMAKE_CURRENT_SOURCE_DIR}/..
|
||||||
GuiPluginInterface TopicReplayInterface TopicEditorInterface Qt6::Core
|
GuiPluginInterface TopicReplayInterface TopicEditorInterface Qt6::Core
|
||||||
)
|
)
|
||||||
|
|
||||||
|
ENDIF(BUILD_RTI)
|
||||||
+1
@@ -130,6 +130,7 @@ NGL_ADD_LIBRARY2(WS SitmapDds SHARED ${sitmap_dds_SRCS})
|
|||||||
NGL_TARGET_INCLUDE_DIRECTORIES(SitmapDds
|
NGL_TARGET_INCLUDE_DIRECTORIES(SitmapDds
|
||||||
PUBLIC
|
PUBLIC
|
||||||
${CMAKE_CURRENT_SOURCE_DIR}/../
|
${CMAKE_CURRENT_SOURCE_DIR}/../
|
||||||
|
${CMAKE_SOURCE_DIR}/Lts/Viewer/SituationMap
|
||||||
)
|
)
|
||||||
NGL_TARGET_LINK_LIBRARIES(SitmapDds
|
NGL_TARGET_LINK_LIBRARIES(SitmapDds
|
||||||
PUBLIC
|
PUBLIC
|
||||||
|
|||||||
@@ -4,6 +4,8 @@
|
|||||||
# $Author$
|
# $Author$
|
||||||
#
|
#
|
||||||
|
|
||||||
|
IF(BUILD_RTI)
|
||||||
|
|
||||||
SET(xml_FILE dgps_service.xml)
|
SET(xml_FILE dgps_service.xml)
|
||||||
|
|
||||||
SET(if_SRCS
|
SET(if_SRCS
|
||||||
@@ -66,3 +68,5 @@ NGL_TARGET_LINK_LIBRARIES(Tetra_dgps_simulator
|
|||||||
Qt6::Core
|
Qt6::Core
|
||||||
Qt6::Network
|
Qt6::Network
|
||||||
)
|
)
|
||||||
|
|
||||||
|
ENDIF(BUILD_RTI)
|
||||||
@@ -3,6 +3,8 @@
|
|||||||
#include "tetra_if.h"
|
#include "tetra_if.h"
|
||||||
#include "dgps_config.h"
|
#include "dgps_config.h"
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
|
|
||||||
#include <NGLLogger/NGLLoggerBootstrap.h>
|
#include <NGLLogger/NGLLoggerBootstrap.h>
|
||||||
#include <QTcpSocket>
|
#include <QTcpSocket>
|
||||||
#include <QHostAddress>
|
#include <QHostAddress>
|
||||||
@@ -243,3 +245,5 @@ void TetraIF::onAddGroupMonitoring()
|
|||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif // BUILD_RTI
|
||||||
@@ -9,7 +9,7 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <NGLLogger/INGLLogger.h>
|
#include <NGLLogger/INGLLogger.h>
|
||||||
#include "svcalmcommon_export.h"
|
#include <AlarmManagement/svcalmcommon_export.h>
|
||||||
|
|
||||||
namespace AlarmManagement
|
namespace AlarmManagement
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -17,12 +17,11 @@
|
|||||||
#include "logger.h"
|
#include "logger.h"
|
||||||
#include <LtsUtilsCore/connection.h>
|
#include <LtsUtilsCore/connection.h>
|
||||||
#include <QString>
|
#include <QString>
|
||||||
|
#include <QStringList>
|
||||||
#include <QVector>
|
#include <QVector>
|
||||||
#include <QObject>
|
#include <QObject>
|
||||||
#include <chrono>
|
#include <chrono>
|
||||||
|
|
||||||
class QStringList;
|
|
||||||
|
|
||||||
namespace AudioVideoManagement
|
namespace AudioVideoManagement
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|||||||
@@ -9,13 +9,13 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <NGLLogger/INGLLogger.h>
|
#include <NGLLogger/INGLLogger.h>
|
||||||
#include "svcmrkcommon_export.h"
|
#include <MarkerManagement/svcmrkcommon_export.h>
|
||||||
|
|
||||||
namespace MarkerManagement
|
namespace MarkerManagement
|
||||||
{
|
{
|
||||||
using LOGGER_T = NGL::INGLLogger &;
|
using LOGGER_T = NGL::INGLLogger &;
|
||||||
|
|
||||||
MRK_COMMON_EXPORT LOGGER_T getLogger(const char *name);
|
SVCMRKCOMMON_EXPORT LOGGER_T getLogger(const char *name);
|
||||||
inline LOGGER_T getLogger(const QString &loggerName)
|
inline LOGGER_T getLogger(const QString &loggerName)
|
||||||
{
|
{
|
||||||
return getLogger(loggerName.toUtf8().constData());
|
return getLogger(loggerName.toUtf8().constData());
|
||||||
|
|||||||
@@ -4,6 +4,8 @@
|
|||||||
# $Author$
|
# $Author$
|
||||||
#
|
#
|
||||||
|
|
||||||
|
IF(BUILD_RTI)
|
||||||
ADD_SUBDIRECTORY(CoPrtCnv)
|
ADD_SUBDIRECTORY(CoPrtCnv)
|
||||||
ADD_SUBDIRECTORY(LogView)
|
ADD_SUBDIRECTORY(LogView)
|
||||||
ADD_SUBDIRECTORY(PrtCnv)
|
ADD_SUBDIRECTORY(PrtCnv)
|
||||||
|
ENDIF()
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
#ifndef SVCALMCOMMON_EXPORT_H
|
||||||
|
#define SVCALMCOMMON_EXPORT_H
|
||||||
|
|
||||||
|
// Stub export macro for AlarmManagement
|
||||||
|
#define SVCALMCOMMON_EXPORT
|
||||||
|
#define SVCALMCOMMON_NO_EXPORT
|
||||||
|
|
||||||
|
#endif // SVCALMCOMMON_EXPORT_H
|
||||||
@@ -3,6 +3,10 @@
|
|||||||
// STUB-HEADER: Diese Datei wird normalerweise von ddsdtc generiert
|
// STUB-HEADER: Diese Datei wird normalerweise von ddsdtc generiert
|
||||||
// Für die Migration erstellen wir minimale Typ-Definitionen
|
// Für die Migration erstellen wir minimale Typ-Definitionen
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
|
#include <DDS/Core/core.hpp>
|
||||||
|
#endif
|
||||||
|
|
||||||
namespace AudioVideoManagement
|
namespace AudioVideoManagement
|
||||||
{
|
{
|
||||||
// Placeholder enums - werden durch echte DDS-Typen ersetzt
|
// Placeholder enums - werden durch echte DDS-Typen ersetzt
|
||||||
@@ -16,4 +20,12 @@ struct UnitSymbolPosition
|
|||||||
double y = 0.0;
|
double y = 0.0;
|
||||||
double z = 0.0;
|
double z = 0.0;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef BUILD_RTI
|
||||||
|
// RadioSystem wird von DDS generiert
|
||||||
|
using RadioSystem = dds::core::Reference<class RadioSystemObject>;
|
||||||
|
#else
|
||||||
|
// Stub für BUILD_RTI=OFF
|
||||||
|
enum class RadioSystem : int32_t { Cnr = 0, Tvc = 1 };
|
||||||
|
#endif
|
||||||
} // namespace AudioVideoManagement
|
} // namespace AudioVideoManagement
|
||||||
@@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
#include <QString>
|
#include <QtCore/QString>
|
||||||
|
|
||||||
namespace Core
|
namespace Core
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -0,0 +1,7 @@
|
|||||||
|
#ifndef SVCGNACOMMON_EXPORT_H
|
||||||
|
#define SVCGNACOMMON_EXPORT_H
|
||||||
|
|
||||||
|
// Stub export macro for BUILD_RTI=OFF
|
||||||
|
#define SVCGNACOMMON_EXPORT
|
||||||
|
|
||||||
|
#endif // SVCGNACOMMON_EXPORT_H
|
||||||
+12
@@ -0,0 +1,12 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
// Stub export header for LtsProjectionWorkstation
|
||||||
|
// Created for Qt6 migration with BUILD_RTI=OFF
|
||||||
|
|
||||||
|
#ifndef LTSPROJECTIONWORKSTATION_EXPORT_H
|
||||||
|
#define LTSPROJECTIONWORKSTATION_EXPORT_H
|
||||||
|
|
||||||
|
#define LTSPROJECTIONWORKSTATION_EXPORT
|
||||||
|
#define LTSPROJECTIONWORKSTATION_NO_EXPORT
|
||||||
|
|
||||||
|
#endif // LTSPROJECTIONWORKSTATION_EXPORT_H
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
// Auto-generated export macro for PDM Common
|
||||||
|
// Stub for BUILD_RTI=OFF or missing dependency
|
||||||
|
|
||||||
|
#ifndef PDM_COMMON_EXPORT
|
||||||
|
#define PDM_COMMON_EXPORT
|
||||||
|
#endif
|
||||||
Reference in new issue
Block a user