Complete Qt6 migration: full clean build green across groups G1-G12 incl. runtime plugin set
new_docker_build.sh gains Group 12 (212 GUI/Data plugins); fixes LtsUtilsGuiDds visibility (LTO-stripped exports), LtsProjectionWorkstation unity name shadow, 6 unity-off dirs (dup file-scope statics, ddsftc INTERFACE sources) and reconfigures BUILD_FILTERMANAGEMENT/BUILD_PLUGINS_SERVICEMONITOR=ON
This commit is contained in:
1718 files changed
+126739
-18495
No files matched your search
+1
-1
@@ -49,7 +49,7 @@ bool BuildingModel::initModel(const std::shared_ptr<InfrastructureManagement::In
|
||||
}
|
||||
|
||||
for (int currentBuildingId : buildingIds)
|
||||
m_vecData.append(QString::fromStdString(ismDtc->mainStructureElement(currentBuildingId).name()));
|
||||
m_vecData.append(QString::fromStdString(ismDtc->mainStructureElement(currentBuildingId).name));
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
+14
-13
@@ -6,6 +6,7 @@
|
||||
|
||||
#include <InfrastructureManagement/ism_dtc.h>
|
||||
#include <ParticipantManagement/ppm.hpp>
|
||||
#include <ParticipantManagement/ppm_dtc.h>
|
||||
|
||||
#include <LtsCoordTrans/lts_coord_trans.h>
|
||||
|
||||
@@ -62,19 +63,19 @@ QPolygonF getBuildingFootprint(int buildingId, const std::shared_ptr<Infrastruct
|
||||
QVector<QPointF> relPositions;
|
||||
const InfrastructureManagement::MainFootprint &mainFootprint = ismDtc->mainFootprint(buildingId);
|
||||
|
||||
relPositions.reserve(mainFootprint.elements().size());
|
||||
relPositions.reserve(mainFootprint.elements.size());
|
||||
|
||||
for (const InfrastructureManagement::FootprintElement &element : mainFootprint.elements())
|
||||
for (const InfrastructureManagement::FootprintElement &element : mainFootprint.elements)
|
||||
{
|
||||
const Core::RelativePosition &relPos = element.relPosition();
|
||||
const Core::RelativePosition &relPos = element.relPosition;
|
||||
|
||||
relPositions.append(QPointF(relPos.offsetX(), relPos.offsetY()));
|
||||
relPositions.append(QPointF(relPos.offsetX, relPos.offsetY));
|
||||
}
|
||||
|
||||
const InfrastructureManagement::MainStructureElement &mainStructureElement = ismDtc->mainStructureElement(buildingId);
|
||||
const Core::GeoPosition &geoPosition = mainStructureElement.geoPosition();
|
||||
const double angleRad = mainStructureElement.angle() * LtsCoordTrans::deg2rad();
|
||||
const QPointF referencePointGeo(geoPosition.lon(), geoPosition.lat());
|
||||
const Core::GeoPosition &geoPosition = mainStructureElement.geoPosition;
|
||||
const double angleRad = mainStructureElement.angle * LtsCoordTrans::deg2rad();
|
||||
const QPointF referencePointGeo(geoPosition.lon, geoPosition.lat);
|
||||
const LtsCoordTrans::UtmCoordinate referencePointUTM = LtsCoordTrans::UtmCoordinate::fromGeographic(referencePointGeo);
|
||||
const QPointF center;
|
||||
|
||||
@@ -237,19 +238,19 @@ ParticipantProtectionInfo getParticipantProtectionInfo(const QVector<int> &parti
|
||||
{
|
||||
const ParticipantManagement::ParticipantPosition ¤tPosition = ppmDtc->participantPosition(currentParticipantId);
|
||||
|
||||
if (undergroundBuildingIds.contains(currentPosition.buildingId()))
|
||||
if (undergroundBuildingIds.contains(currentPosition.buildingId))
|
||||
{
|
||||
participantProtectionInfo.participantsInUnderground.append(currentParticipantId);
|
||||
continue;
|
||||
}
|
||||
|
||||
if (directlyHitBuildingIds.contains(currentPosition.buildingId()))
|
||||
if (directlyHitBuildingIds.contains(currentPosition.buildingId))
|
||||
{
|
||||
participantProtectionInfo.withoutProtection.append(currentParticipantId);
|
||||
continue;
|
||||
}
|
||||
|
||||
const QPointF geoPosition(currentPosition.pos().lon(), currentPosition.pos().lat());
|
||||
const QPointF geoPosition(currentPosition.pos.lon, currentPosition.pos.lat);
|
||||
|
||||
if (isPointInAnyPolygon(directlyHitBuildingFootprints, geoPosition))
|
||||
{
|
||||
@@ -258,7 +259,7 @@ ParticipantProtectionInfo getParticipantProtectionInfo(const QVector<int> &parti
|
||||
}
|
||||
|
||||
|
||||
if (currentPosition.roomId() != 0)
|
||||
if (currentPosition.roomId != 0)
|
||||
{
|
||||
participantProtectionInfo.withProtection.append(currentParticipantId);
|
||||
continue;
|
||||
@@ -446,8 +447,8 @@ QVector<int> getUndergroundBuildingIds(const QVector<int> &buildingIds, const st
|
||||
for (int currentBuildingId : buildingIds)
|
||||
{
|
||||
const InfrastructureManagement::MainStructureElement &building = ismDtc->mainStructureElement(currentBuildingId);
|
||||
const QString description = QString::fromStdString(building.description());
|
||||
const QString name = QString::fromStdString(building.name());
|
||||
const QString description = QString::fromStdString(building.description);
|
||||
const QString name = QString::fromStdString(building.name);
|
||||
|
||||
if (!(description.contains(kanal, Qt::CaseInsensitive) ||
|
||||
description.contains(uBahn, Qt::CaseInsensitive) ||
|
||||
|
||||
+9
-9
@@ -327,21 +327,21 @@ void CreateSimulationDialog::fillCharges()
|
||||
|
||||
using namespace ProjectDataManagement;
|
||||
|
||||
const QVector<GearClass> gearClasses = { GearClass::AirSupport,
|
||||
GearClass::Artillery,
|
||||
GearClass::Mortar };
|
||||
const QVector<ProjectDataManagement::GearClass> gearClasses = { ProjectDataManagement::GearClass::GearClass_AirSupport,
|
||||
ProjectDataManagement::GearClass::GearClass_Artillery,
|
||||
ProjectDataManagement::GearClass::GearClass_Mortar };
|
||||
|
||||
for (GearClass currentGearClass : gearClasses)
|
||||
for (ProjectDataManagement::GearClass currentGearClass : gearClasses)
|
||||
{
|
||||
const QVector<ChargeType> &chargeTypes = m_pdmDtc->chargesForGearClass(currentGearClass);
|
||||
|
||||
for (const ChargeType ¤tChargeType : chargeTypes)
|
||||
{
|
||||
const QJsonDocument doc(QJsonDocument::fromJson(QByteArray::fromRawData(currentChargeType.properties().c_str(), currentChargeType.properties().size())));
|
||||
const QJsonDocument doc(QJsonDocument::fromJson(QByteArray::fromRawData(currentChargeType.properties.c_str(), currentChargeType.properties.size())));
|
||||
const QJsonObject obj(doc.object());
|
||||
if (!obj.contains(QLatin1String("nasatId")))
|
||||
continue;
|
||||
m_ui->cbChargeTypes->addItem(QString::fromStdString(currentChargeType.name()), currentChargeType.id());
|
||||
m_ui->cbChargeTypes->addItem(QString::fromStdString(currentChargeType.name), currentChargeType.id);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -353,7 +353,7 @@ double CreateSimulationDialog::getCurrentImpactRadius() const
|
||||
{
|
||||
const int chargeTypeId = m_ui->cbChargeTypes->currentData().toInt();
|
||||
const int igniterTypeId = m_ui->cbIgniterType->currentData().toInt();
|
||||
double impactRadius = m_pdmDtc->getChargeTypeIgniterTypeIgniterFunction(chargeTypeId, igniterTypeId, 0).impactRadius();
|
||||
double impactRadius = m_pdmDtc->getChargeTypeIgniterTypeIgniterFunction(chargeTypeId, igniterTypeId, 0).impactRadius;
|
||||
|
||||
DEBUG_LOG(m_logger) << "got impact radius " << impactRadius << " for current charge type " << chargeTypeId << " and igniterTypeId " << igniterTypeId;
|
||||
|
||||
@@ -364,7 +364,7 @@ double CreateSimulationDialog::getLethalRadius() const
|
||||
{
|
||||
const int currentChargeTypeId = m_ui->cbChargeTypes->currentData().toInt();
|
||||
const ProjectDataManagement::ChargeType ¤tChargeType = m_pdmDtc->chargeType(currentChargeTypeId);
|
||||
const QJsonObject properties = QJsonDocument::fromJson(QByteArray::fromStdString(currentChargeType.properties())).object();
|
||||
const QJsonObject properties = QJsonDocument::fromJson(QByteArray::fromStdString(currentChargeType.properties)).object();
|
||||
const QString keyImpactRadius = QStringLiteral("impactRadius");
|
||||
const QString keyCasEffects = QStringLiteral("casEffects");
|
||||
double lethalRadius = DBL_MAX;
|
||||
@@ -392,7 +392,7 @@ double CreateSimulationDialog::getNonLethalRadius() const
|
||||
{
|
||||
const int currentChargeTypeId = m_ui->cbChargeTypes->currentData().toInt();
|
||||
const ProjectDataManagement::ChargeType ¤tChargeType = m_pdmDtc->chargeType(currentChargeTypeId);
|
||||
const QJsonObject properties = QJsonDocument::fromJson(QByteArray::fromStdString(currentChargeType.properties())).object();
|
||||
const QJsonObject properties = QJsonDocument::fromJson(QByteArray::fromStdString(currentChargeType.properties)).object();
|
||||
const QString keyImpactRadius = QStringLiteral("impactRadius");
|
||||
const QString keyCasEffects = QStringLiteral("casEffects");
|
||||
double nonLethalRadius = 0.0;
|
||||
|
||||
+1
-1
@@ -7,7 +7,7 @@
|
||||
|
||||
#include "cds_create_simulation_dialog.h"
|
||||
|
||||
#include <flm_data_plugin_interface.h>
|
||||
#include <Plugins/FileManagement/flm_data_plugin_interface.h>
|
||||
#include <InfrastructureManagement/Data/ism_data_plugin.h>
|
||||
#include <ParticipantManagement/Data/ppm_data_plugin.h>
|
||||
#include <ProjectDataManagement/Data/pdm_data_plugin.h>
|
||||
|
||||
+6
-5
@@ -4,6 +4,7 @@
|
||||
#include "cds_participant_model.h"
|
||||
|
||||
#include <ParticipantManagement/ppm.hpp>
|
||||
#include <ParticipantManagement/ppm_dtc.h>
|
||||
|
||||
namespace CollateralDamageSimulation
|
||||
{
|
||||
@@ -34,21 +35,21 @@ QVariant ParticipantModel::data(const QModelIndex &index, int role) const
|
||||
{
|
||||
case PARTY:
|
||||
{
|
||||
const int partyId = participant.partyId();
|
||||
const int partyId = participant.partyId;
|
||||
|
||||
if (!m_partyCache.contains(partyId))
|
||||
m_partyCache.insert(partyId, m_ppmDtc->party(partyId));
|
||||
|
||||
const ParticipantManagement::Party &party = m_partyCache.value(partyId);
|
||||
|
||||
return QString::fromStdString(party.name());
|
||||
return QString::fromStdString(party.name);
|
||||
}
|
||||
case EQUIPMENT_NUMBER:
|
||||
return participant.equipmentNumber().is_set() ? participant.equipmentNumber().get() : 0;
|
||||
return participant.equipmentNumber.has_value() ? participant.equipmentNumber.get() : 0;
|
||||
case DESIGNATOR:
|
||||
return QString::fromStdString(participant.designator());
|
||||
return QString::fromStdString(participant.designator);
|
||||
case TACTICAL_IDENTIFIER:
|
||||
return QString::fromStdString(participant.tacticalIdentifier());
|
||||
return QString::fromStdString(participant.tacticalIdentifier);
|
||||
default:
|
||||
return QVariant();
|
||||
}
|
||||
|
||||
+20
-19
@@ -5,6 +5,7 @@
|
||||
|
||||
#include <InfrastructureManagement/ism_dtc.h>
|
||||
#include <ParticipantManagement/ppm.hpp>
|
||||
#include <ParticipantManagement/ppm_dtc.h>
|
||||
#include <Lts/Services/FileManagement/flm_ftc.h>
|
||||
|
||||
#include <QtCore/QDateTime>
|
||||
@@ -98,7 +99,7 @@ void PdfCreator::addBuildings(const QVector<int> &buildingIds)
|
||||
{
|
||||
const InfrastructureManagement::MainStructureElement ¤tBuilding = m_ismDtc->mainStructureElement(currentBuildingId);
|
||||
|
||||
KDReports::TextElement name(QString::fromStdString(currentBuilding.name()));
|
||||
KDReports::TextElement name(QString::fromStdString(currentBuilding.name));
|
||||
|
||||
table.cell(row, 0).addElement(name);
|
||||
|
||||
@@ -131,17 +132,17 @@ void PdfCreator::save(const QString &name, int folderId, int exerciseId)
|
||||
|
||||
FileManagement::FileContentModifyRequest data;
|
||||
|
||||
data.name(name.toStdString());
|
||||
data.isTemplate(false);
|
||||
data.isHidden(false);
|
||||
data.folderId(folderId);
|
||||
data.fileStatus(FileManagement::FileStatus::Valid);
|
||||
data.fileCategory(FileManagement::FileCategory::Exercise);
|
||||
data.fileType(FileManagement::FileType::Pdf);
|
||||
data.operatorId(LtsSessionData::LtsSessionData::getInstance()->getOperatorId());
|
||||
data.lastModified(QDateTime::currentMSecsSinceEpoch());
|
||||
data.content(LtsUtils::convert<std::vector<uint8_t>>(saveFile.readAll()));
|
||||
data.exerciseId(exerciseId);
|
||||
data.name = name.toStdString();
|
||||
data.isTemplate = false;
|
||||
data.isHidden = false;
|
||||
data.folderId = folderId;
|
||||
data.fileStatus = FileManagement::FileStatus::Valid;
|
||||
data.fileCategory = FileManagement::FileCategory::Exercise;
|
||||
data.fileType = FileManagement::FileType::Pdf;
|
||||
data.operatorId = LtsSessionData::LtsSessionData::getInstance()->getOperatorId();
|
||||
data.lastModified = QDateTime::currentMSecsSinceEpoch();
|
||||
data.content = LtsUtils::convert<std::vector<uint8_t>>(saveFile.readAll());
|
||||
data.exerciseId = exerciseId;
|
||||
|
||||
bool isModifyRequestOk = m_flmFtc->fileContentModifyRequest(data, [this](const Core::FunctionReplyObject &reply)
|
||||
{
|
||||
@@ -202,17 +203,17 @@ void PdfCreator::addParticipantTable(const QVector<int> &participantIds, const Q
|
||||
int column = 0;
|
||||
const ParticipantManagement::Participant ¤tParticipant = m_ppmDtc->participant(currentParticipantId);
|
||||
|
||||
if (!partyNames.contains(currentParticipant.partyId()))
|
||||
if (!partyNames.contains(currentParticipant.partyId))
|
||||
{
|
||||
const ParticipantManagement::Party &party = m_ppmDtc->party(currentParticipant.partyId());
|
||||
const ParticipantManagement::Party &party = m_ppmDtc->party(currentParticipant.partyId);
|
||||
|
||||
partyNames.insert(party.id(), QString::fromStdString(party.name()));
|
||||
partyNames.insert(party.id, QString::fromStdString(party.name));
|
||||
}
|
||||
|
||||
KDReports::TextElement party(partyNames.value(currentParticipant.partyId()));
|
||||
KDReports::TextElement equipmentNumber(QString::number(currentParticipant.equipmentNumber().is_set() ? currentParticipant.equipmentNumber().get() : 0));
|
||||
KDReports::TextElement designation(QString::fromStdString(currentParticipant.designator()));
|
||||
KDReports::TextElement tacticalIdentifier(QString::fromStdString(currentParticipant.tacticalIdentifier()));
|
||||
KDReports::TextElement party(partyNames.value(currentParticipant.partyId));
|
||||
KDReports::TextElement equipmentNumber(QString::number(currentParticipant.equipmentNumber.has_value() ? currentParticipant.equipmentNumber.get() : 0));
|
||||
KDReports::TextElement designation(QString::fromStdString(currentParticipant.designator));
|
||||
KDReports::TextElement tacticalIdentifier(QString::fromStdString(currentParticipant.tacticalIdentifier));
|
||||
|
||||
table.cell(row, column++).addElement(party);
|
||||
table.cell(row, column++).addElement(equipmentNumber);
|
||||
|
||||
+18
-17
@@ -9,6 +9,7 @@
|
||||
|
||||
#include <InfrastructureManagement/ism_dtc.h>
|
||||
#include <ParticipantManagement/ppm.hpp>
|
||||
#include <ParticipantManagement/ppm_dtc.h>
|
||||
#include <Lts/Services/FileManagement/flm_ftc.h>
|
||||
|
||||
#include <QtGui/QPolygonF>
|
||||
@@ -115,17 +116,17 @@ void PlanCreator::save(const QString &name, int folderId, int exerciseId)
|
||||
|
||||
FileManagement::FileContentModifyRequest data;
|
||||
|
||||
data.name(name.toStdString());
|
||||
data.isTemplate(false);
|
||||
data.isHidden(false);
|
||||
data.folderId(folderId);
|
||||
data.fileStatus(FileManagement::FileStatus::Valid);
|
||||
data.fileCategory(FileManagement::FileCategory::Exercise);
|
||||
data.fileType(FileManagement::FileType::TacticalPlan);
|
||||
data.operatorId(LtsSessionData::LtsSessionData::getInstance()->getOperatorId());
|
||||
data.lastModified(QDateTime::currentMSecsSinceEpoch());
|
||||
data.content(LtsUtils::convert<std::vector<uint8_t>>(m_geometryModel->toByteArray()));
|
||||
data.exerciseId(exerciseId);
|
||||
data.name = name.toStdString();
|
||||
data.isTemplate = false;
|
||||
data.isHidden = false;
|
||||
data.folderId = folderId;
|
||||
data.fileStatus = FileManagement::FileStatus::Valid;
|
||||
data.fileCategory = FileManagement::FileCategory::Exercise;
|
||||
data.fileType = FileManagement::FileType::TacticalPlan;
|
||||
data.operatorId = LtsSessionData::LtsSessionData::getInstance()->getOperatorId();
|
||||
data.lastModified = QDateTime::currentMSecsSinceEpoch();
|
||||
data.content = LtsUtils::convert<std::vector<uint8_t>>(m_geometryModel->toByteArray());
|
||||
data.exerciseId = exerciseId;
|
||||
|
||||
bool isModifyRequestOk = m_flmFtc->fileContentModifyRequest(data, [this](const Core::FunctionReplyObject &reply)
|
||||
{
|
||||
@@ -233,23 +234,23 @@ void PlanCreator::addParticipant(int participantId, ProtectionState protectionSt
|
||||
const ParticipantManagement::Participant &participant = m_ppmDtc->participant(participantId);
|
||||
const ParticipantManagement::ParticipantPosition &position = m_ppmDtc->participantPosition(participantId);
|
||||
|
||||
if (!m_partyCache.contains(participant.partyId()))
|
||||
m_partyCache.insert(participant.partyId(), m_ppmDtc->party(participant.partyId()));
|
||||
if (!m_partyCache.contains(participant.partyId))
|
||||
m_partyCache.insert(participant.partyId, m_ppmDtc->party(participant.partyId));
|
||||
|
||||
QList<QPair<GeometryModel::Attribute, QVariant>> symbolAttributes;
|
||||
QPointF positionPoint(position.pos().lon(), position.pos().lat());
|
||||
QPointF positionPoint(position.pos.lon, position.pos.lat);
|
||||
const QList<QPointF> positionList = {positionPoint};
|
||||
|
||||
|
||||
symbolAttributes.reserve(2);
|
||||
|
||||
QString sidc = QString::fromStdString(participant.symbol());
|
||||
QString sidc = QString::fromStdString(participant.symbol);
|
||||
|
||||
if (sidc.size() > 16)
|
||||
sidc.replace(16, 1, QString::number(static_cast<int>(protectionState)));
|
||||
|
||||
symbolAttributes.append(QPair<GeometryModel::Attribute, QVariant>(GeometryModel::Attribute::SIDC, QVariant(sidc)));
|
||||
symbolAttributes.append(QPair<GeometryModel::Attribute, QVariant>(GeometryModel::Attribute::ForceId, QVariant(participant.partyId())));
|
||||
symbolAttributes.append(QPair<GeometryModel::Attribute, QVariant>(GeometryModel::Attribute::ForceId, QVariant(participant.partyId)));
|
||||
|
||||
m_geometryModel->addPrimitive(GeometryModel::PrimitiveType::ParticipantSymbol, positionList, symbolAttributes);
|
||||
}
|
||||
@@ -275,7 +276,7 @@ void PlanCreator::addProtectionArea(const QPolygonF &areaPolygon)
|
||||
|
||||
SymbologyXML::SymbolTypes::t_affil PlanCreator::partyRoleToSymbolAffiliation(const ParticipantManagement::Role &partyRole) const
|
||||
{
|
||||
switch (partyRole.underlying())
|
||||
switch (partyRole)
|
||||
{
|
||||
case ParticipantManagement::Role::Unknown:
|
||||
return SymbologyXML::SymbolTypes::UNKNOWN;
|
||||
|
||||
+1
@@ -9,6 +9,7 @@
|
||||
#include <SymbologyXML/symbol_types.h>
|
||||
#include <ParticipantManagement/ppm_enums.hpp>
|
||||
#include <ParticipantManagement/ppm.hpp>
|
||||
#include <ParticipantManagement/ppm_dtc.h>
|
||||
#include <SituationMap/GeometryModel/geometry_model.h>
|
||||
|
||||
namespace FileManagement
|
||||
|
||||
+1
@@ -6,6 +6,7 @@
|
||||
|
||||
#include <InfrastructureManagement/ism_dtc.h>
|
||||
#include <ParticipantManagement/ppm.hpp>
|
||||
#include <ParticipantManagement/ppm_dtc.h>
|
||||
|
||||
#include "cds_building_model.h"
|
||||
#include "cds_participant_model.h"
|
||||
|
||||
Reference in new issue
Block a user