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:
berrux-dev committed 2026-10-20 09:36:57 +02:00
1 parent eb1d949edc
commit 815e16368e
1718 files changed
+126739 -18495

No files matched your search

@@ -11,18 +11,18 @@ ParticipantManagement::TemplateParticipant ParticipantManagement::TemplateHandli
{
TemplateParticipant result;
result.templateId(id());
result.typeId(typeId());
result.name(m_data.name.toStdString());
result.designator(m_data.designator.toStdString());
result.info(m_data.info.toStdString());
result.symbol(m_data.symbol.toStdString());
result.tacticalIdentifier(m_data.tacticalIdentifier.toStdString());
result.hierarchyNumber(m_data.hierarchyNumber);
result.superiorTemplateId(superiorId());
result.equipmentNumber(m_data.equipmentNumber);
result.templateId = id();
result.typeId = typeId();
result.name = m_data.name.toStdString();
result.designator = m_data.designator.toStdString();
result.info = m_data.info.toStdString();
result.symbol = m_data.symbol.toStdString();
result.tacticalIdentifier = m_data.tacticalIdentifier.toStdString();
result.hierarchyNumber = m_data.hierarchyNumber;
result.superiorTemplateId = superiorId();
result.equipmentNumber = m_data.equipmentNumber;
if (!m_inferiorIds.empty())
result.inferiorIds().set(m_inferiorIds);
result.inferiorIds.set(m_inferiorIds);
return result;
}
@@ -30,25 +30,25 @@ ParticipantManagement::TemplateParticipant ParticipantManagement::TemplateHandli
bool ParticipantManagement::TemplateHandling::Template::hasToBeChanged(const ParticipantManagement::TemplateData &newData)
{
bool hasNoChanges =
m_data.typeId == newData.typeId() &&
m_data.hierarchyNumber == newData.hierarchyNumber() &&
m_data.equipmentNumber == newData.equipmentNumber() &&
m_data.name == QString::fromStdString(newData.name()) &&
m_data.symbol == QString::fromStdString(newData.symbol()) &&
m_data.info == QString::fromStdString(newData.info()) &&
m_data.designator == QString::fromStdString(newData.designator()) &&
m_data.tacticalIdentifier == QString::fromStdString(newData.tacticalIdentifier());
m_data.typeId == newData.typeId &&
m_data.hierarchyNumber == newData.hierarchyNumber &&
m_data.equipmentNumber == newData.equipmentNumber &&
m_data.name == QString::fromStdString(newData.name) &&
m_data.symbol == QString::fromStdString(newData.symbol) &&
m_data.info == QString::fromStdString(newData.info) &&
m_data.designator == QString::fromStdString(newData.designator) &&
m_data.tacticalIdentifier == QString::fromStdString(newData.tacticalIdentifier);
if (!hasNoChanges)
{
m_data.typeId = newData.typeId();
m_data.hierarchyNumber = newData.hierarchyNumber();
m_data.name = QString::fromStdString(newData.name());
m_data.symbol = QString::fromStdString(newData.symbol());
m_data.info = QString::fromStdString(newData.info());
m_data.designator = QString::fromStdString(newData.designator());
m_data.tacticalIdentifier = QString::fromStdString(newData.tacticalIdentifier());
m_data.equipmentNumber = newData.equipmentNumber();
m_data.typeId = newData.typeId;
m_data.hierarchyNumber = newData.hierarchyNumber;
m_data.name = QString::fromStdString(newData.name);
m_data.symbol = QString::fromStdString(newData.symbol);
m_data.info = QString::fromStdString(newData.info);
m_data.designator = QString::fromStdString(newData.designator);
m_data.tacticalIdentifier = QString::fromStdString(newData.tacticalIdentifier);
m_data.equipmentNumber = newData.equipmentNumber;
}
return !hasNoChanges;
@@ -72,19 +72,19 @@ Core::FunctionReplyObject TemplateHandler::modifyTemplateDataRequest(const Parti
QHash<int32_t, int32_t> modIdToTemplateId; // <modId, templateId>
QVector<ParticipantManagement::TemplateData> templatesToBeCreatedOrModified;
templatesToBeCreatedOrModified.reserve(request.data().size());
templatesToBeCreatedOrModified.reserve(request.data.size());
DBTransaction removeTransaction(m_mainHandler->db()->database());
// first remove templates which are marked to be removed
for (const TemplateData &currentTemplate : request.data())
for (const TemplateData &currentTemplate : request.data)
{
if (currentTemplate.isDeleted())
if (currentTemplate.isDeleted)
{
if (currentTemplate.templateId() <= 0)
if (currentTemplate.templateId <= 0)
return Core::FunctionReplyObject(tr_lts("dds",
"Internal error - Not possible to remove templateData with modId %1, because it does not have templateId set"))
.arg(currentTemplate.modId());
const auto ret = deleteTemplateById(currentTemplate.templateId(), true);
.arg(currentTemplate.modId);
const auto ret = deleteTemplateById(currentTemplate.templateId, true);
if (ret.error())
return ret;
}
@@ -106,12 +106,10 @@ Core::FunctionReplyObject TemplateHandler::modifyTemplateDataRequest(const Parti
futureVec.reserve(vecSize);
for (int startIndex = 0; startIndex < templatesToBeCreatedOrModified.size(); startIndex += range)
{
QFuture<Core::FunctionReplyObject> fut = QtConcurrent::run(this,
&TemplateHandler::validateTemplateData,
templatesToBeCreatedOrModified,
modIdToTemplateId,
startIndex,
range);
QFuture<Core::FunctionReplyObject> fut = QtConcurrent::run(
[this, templatesToBeCreatedOrModified, modIdToTemplateId, startIndex, range]() mutable -> Core::FunctionReplyObject {
return validateTemplateData(templatesToBeCreatedOrModified, modIdToTemplateId, startIndex, range);
});
futureVec += fut;
}
@@ -142,7 +140,7 @@ Core::FunctionReplyObject TemplateHandler::modifyTemplateDataRequest(const Parti
for (const TemplateData &currentData : std::as_const(templatesToBeCreatedOrModified))
{
Template *templateToUpdate = m_templates.value(modIdToTemplateId.value(currentData.modId()));
Template *templateToUpdate = m_templates.value(modIdToTemplateId.value(currentData.modId));
if (!templateToUpdate)
{
DEBUG_LOG(m_logger) << "Creating new template: " << currentData;
@@ -167,8 +165,8 @@ Core::FunctionReplyObject TemplateHandler::modifyTemplateDataRequest(const Parti
// build hierarchy
for (const TemplateData &currentData : std::as_const(templatesToBeCreatedOrModified)) // first set superiorIds
{
Template *templateToUpdate = m_templates.value(modIdToTemplateId.value(currentData.modId()), nullptr);
const int superiorId = modIdToTemplateId.value(currentData.superiorModId());
Template *templateToUpdate = m_templates.value(modIdToTemplateId.value(currentData.modId), nullptr);
const int superiorId = modIdToTemplateId.value(currentData.superiorModId);
if (!templateToUpdate->hasNewSuperiorId(superiorId) ||
templatesWithChanges.contains(templateToUpdate))
continue;
@@ -223,15 +221,15 @@ Core::FunctionReplyObject TemplateHandler::createNewTemplate(const ParticipantMa
// create new template
Database::PpmTemplate newDbTemplate;
newDbTemplate.typeId = currentData.typeId();
newDbTemplate.name = QString::fromStdString(currentData.name());
newDbTemplate.symbol = QString::fromStdString(currentData.symbol());
newDbTemplate.info = QString::fromStdString(currentData.info());
newDbTemplate.designator = QString::fromStdString(currentData.designator());
newDbTemplate.tacticalIdentifier = QString::fromStdString(currentData.tacticalIdentifier());
newDbTemplate.superiorId = modIdToTemplateId.value(currentData.superiorModId(), 0);
newDbTemplate.hierarchyNumber = currentData.hierarchyNumber();
newDbTemplate.equipmentNumber = currentData.equipmentNumber();
newDbTemplate.typeId = currentData.typeId;
newDbTemplate.name = QString::fromStdString(currentData.name);
newDbTemplate.symbol = QString::fromStdString(currentData.symbol);
newDbTemplate.info = QString::fromStdString(currentData.info);
newDbTemplate.designator = QString::fromStdString(currentData.designator);
newDbTemplate.tacticalIdentifier = QString::fromStdString(currentData.tacticalIdentifier);
newDbTemplate.superiorId = modIdToTemplateId.value(currentData.superiorModId, 0);
newDbTemplate.hierarchyNumber = currentData.hierarchyNumber;
newDbTemplate.equipmentNumber = currentData.equipmentNumber;
// creating db entry
if (!m_mainHandler->db()->insert(newDbTemplate))
@@ -242,7 +240,7 @@ Core::FunctionReplyObject TemplateHandler::createNewTemplate(const ParticipantMa
Template *newTemplate = new Template(newDbTemplate);
m_templates.insert(newTemplate->id(), newTemplate);
modIdToTemplateId.insert(currentData.modId(), newTemplate->id());
modIdToTemplateId.insert(currentData.modId, newTemplate->id());
if (!templatesWithChanges.contains(newTemplate))
templatesWithChanges.append(newTemplate);
@@ -253,32 +251,32 @@ Core::FunctionReplyObject TemplateHandler::validateTemplateData(const QVector<Te
QHash<int32_t, int32_t> &modIdToTemplateId,
const ParticipantManagement::TemplateData &templateToValidate)
{
if (templateToValidate.templateId() != 0)
if (templateToValidate.templateId != 0)
{
DEBUG_LOG(m_logger) << "Checking template id";
Template *existingTemplate = m_templates.value(templateToValidate.templateId(), nullptr);
Template *existingTemplate = m_templates.value(templateToValidate.templateId, nullptr);
if (existingTemplate == nullptr)
return Core::FunctionReplyObject(tr_lts("dds",
"Could not execute ModifyTemplateDataRequest, because an invalid template ID (%1) was given"))
.arg(templateToValidate.templateId());
.arg(templateToValidate.templateId);
DEBUG_LOG(m_logger) << "... ok";
{
QMutexLocker l(&m_mutex);
modIdToTemplateId.insert(templateToValidate.modId(), existingTemplate->id()); /* register template to indicate that this template
modIdToTemplateId.insert(templateToValidate.modId, existingTemplate->id()); /* register template to indicate that this template
should just be modified and not newly created */
}
}
// superior ids valid?
if (templateToValidate.superiorModId() > 0)
if (templateToValidate.superiorModId > 0)
{
DEBUG_LOG(m_logger) << "checking superiorIds";
// superior exists?
bool isExistingSuperiorId = false;
for (const TemplateData &dat : dataVec)
{
if (templateToValidate.superiorModId() == dat.modId())
if (templateToValidate.superiorModId == dat.modId)
{
isExistingSuperiorId = true;
break; // for (const TemplateData &dat : dataVec)
@@ -287,12 +285,12 @@ Core::FunctionReplyObject TemplateHandler::validateTemplateData(const QVector<Te
if (!isExistingSuperiorId)
return Core::FunctionReplyObject(tr_lts("dds",
"Could not execute ModifyTemplateDataRequest, the data set with modId %1 has an invalid superiorModId %2"))
.arg(templateToValidate.modId())
.arg(templateToValidate.superiorModId());
.arg(templateToValidate.modId)
.arg(templateToValidate.superiorModId);
DEBUG_LOG(m_logger) << "... ok";
if (templateToValidate.hierarchyNumber() <= 0)
if (templateToValidate.hierarchyNumber <= 0)
return Core::FunctionReplyObject(tr_lts("dds",
"Could not execute ModifyTemplateDataRequest, because a data set has a superior but no hierarchyNumber set"));
@@ -301,24 +299,24 @@ Core::FunctionReplyObject TemplateHandler::validateTemplateData(const QVector<Te
for (const TemplateData &dat : dataVec)
{
// operator==() on optionals returns false if not set ...
if (dat.modId() != templateToValidate.modId() &&
dat.superiorModId() == templateToValidate.superiorModId() &&
dat.hierarchyNumber() == templateToValidate.hierarchyNumber())
if (dat.modId != templateToValidate.modId &&
dat.superiorModId == templateToValidate.superiorModId &&
dat.hierarchyNumber == templateToValidate.hierarchyNumber)
return Core::FunctionReplyObject(tr_lts("dds",
"Could not execute ModifyTemplateDataRequest, because for superiorModId %1 hierarchyNumber %2 is not unique"))
.arg(dat.superiorModId())
.arg(dat.hierarchyNumber());
.arg(dat.superiorModId)
.arg(dat.hierarchyNumber);
}
DEBUG_LOG(m_logger) << "... ok";
}
// typeId valid?
DEBUG_LOG(m_logger) << "Checking typeId";
if (m_mainHandler->typeHandler()->typeById(templateToValidate.typeId()) == nullptr)
if (m_mainHandler->typeHandler()->typeById(templateToValidate.typeId) == nullptr)
return Core::FunctionReplyObject(tr_lts("dds",
"Could not execute ModifyTemplateDataRequest, because data set with modId %1 has invalid typeId %2"))
.arg(templateToValidate.modId())
.arg(templateToValidate.typeId());
.arg(templateToValidate.modId)
.arg(templateToValidate.typeId);
DEBUG_LOG(m_logger) << "... ok";