Qt6 Migration: DDS-Stubs, Logger-Fixes, Export-Header Korrekturen
- NGL_ADD_LIBRARY2: 87 CMakeLists.txt konvertiert für Export-Header Generierung - 44 Export-Header Include-Pfade korrigiert (_export.h) - 81 DDS-Stub-Header generiert (*_dtc.h, *_fts.h, *_dts.h, *_ftc.h) - INGLLogger: Duplikat gelöscht, m_logger Member entfernt, variadische Makros - Q_FUNC_INFO Redefinition behoben (Qt6 definiert bereits) - FATAL_LOG Makro hinzugefügt - InfrastructureManagement DDS-Stubs (ism.hpp, ism_enums.hpp, ism_ftc.h) - FilterManagement DDS-Stubs (flt_ftc.h, flt_dts.h) - AreaEffectSimulation DDS-Stubs (aes.hpp, aes_enums.hpp) - SymbolAppearance Klasse vollständig definiert mit content() Methode - BuildingComponentFilter Klasse definiert mit Copy-Konstruktor - Ftc Factory: nullptr Return (abstract class) - AesFilter Klasse in aes.hpp hinzugefügt - Dtc Klasse in ppm.hpp mit participantChanged Signal - AesType Enum: alle 15 At* Werte definiert - AesEffectState_def: EsReceived hinzugefügt - DataModification Enum: eAdded/eModified/eRemoved - function_reply_object.h → core_types.h Include-Pfad (72 Dateien) - Enum-Class-Streaming Template-Operator in INGLLogger.h - ism_mounting_point.h: QImage → QtGui/QImage, QGuiApplication/QScreen - ism_data_plugin_interface.h: QSet Include, Include-Reihenfolge - QRegExp → QRegularExpression in tpm_js_parser.cpp - .underlying() Aufrufe zu direktem Enum-Vergleich korrigiert - Include-Pfade: aes.hpp in symbol_appearance_settings_impl.h und aes_display_filter_impl.h Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
2785 files changed
+18754
-18316
No files matched your search
@@ -22,21 +22,20 @@ namespace GuezNasat
|
||||
HandlerNasatImpact::HandlerNasatImpact(Initialization *mainHandler)
|
||||
: AreaEffectSimulation::Interface::Ftc::AirSupportImpactModifyReplyHandler()
|
||||
, m_mainHandler(mainHandler)
|
||||
, m_logger(getLogger("HandlerNasatImpact"))
|
||||
{
|
||||
TRACE_LOG(m_logger) << LOGFUNCTION << " START";
|
||||
TRACE_LOG() << Q_FUNC_INFO << " START";
|
||||
auto pdmDtc = m_mainHandler->dds()->pdmDtc();
|
||||
connect(pdmDtc.get(), &ProjectDataManagement::Interface::Dtc::chargeTypeChanged,
|
||||
this, &HandlerNasatImpact::onChargeTypeChanged);
|
||||
pdmDtc->chargeTypes([this](const ProjectDataManagement::ChargeType &ct) { onChargeTypeChanged(ct);});
|
||||
|
||||
#ifdef TRIGGER_DUMMY_IMPACT
|
||||
FATAL_LOG(m_logger) << LOGFUNCTION << " prepare singleShot...";
|
||||
FATAL_LOG(m_logger) << Q_FUNC_INFO << " prepare singleShot...";
|
||||
|
||||
QTimer *timer = new QTimer;
|
||||
timer->setInterval(30000);
|
||||
connect(timer, &QTimer::timeout, [this] () {
|
||||
FATAL_LOG(m_logger) << LOGFUNCTION << " singleShot...";
|
||||
FATAL_LOG(m_logger) << Q_FUNC_INFO << " singleShot...";
|
||||
|
||||
NasatWeaponRelease wr;
|
||||
wr.aircraftId = 1;
|
||||
@@ -54,38 +53,38 @@ HandlerNasatImpact::HandlerNasatImpact(Initialization *mainHandler)
|
||||
|
||||
this->nasatWeaponRelease(wr);
|
||||
|
||||
FATAL_LOG(m_logger) << LOGFUNCTION << " singleShot...DONE";
|
||||
FATAL_LOG(m_logger) << Q_FUNC_INFO << " singleShot...DONE";
|
||||
});
|
||||
timer->start();
|
||||
|
||||
#endif
|
||||
|
||||
TRACE_LOG(m_logger) << LOGFUNCTION << " END";
|
||||
TRACE_LOG() << Q_FUNC_INFO << " END";
|
||||
}
|
||||
|
||||
void HandlerNasatImpact::onAirSupportImpactModifyReply(const Core::FunctionReplyObject &reply)
|
||||
{
|
||||
if (reply.error())
|
||||
WARNING_LOG(m_logger) << "Could not create single explosion for nasat impact: " << reply();
|
||||
WARNING_LOG() << "Could not create single explosion for nasat impact: " << reply();
|
||||
|
||||
#ifdef NLDEVCTRL_844
|
||||
testing.replyCounter++;
|
||||
INFO_LOG(m_logger) << "Got create reply: " << reply() << "(id=" << reply.id() << ")"
|
||||
INFO_LOG() << "Got create reply: " << reply() << "(id=" << reply.id() << ")"
|
||||
<< ", this=" << this
|
||||
<< " - replyCounter=" << testing.replyCounter;
|
||||
#else
|
||||
INFO_LOG(m_logger) << "Got create reply: " << reply() << "(id=" << reply.id() << ")"
|
||||
INFO_LOG() << "Got create reply: " << reply() << "(id=" << reply.id() << ")"
|
||||
<< ", this=" << this;
|
||||
#endif
|
||||
}
|
||||
|
||||
void HandlerNasatImpact::onExplosionClusterModifyReply(const Core::FunctionReplyObject &reply)
|
||||
{
|
||||
INFO_LOG(m_logger) << "Got create reply: " << reply() << "(id=" << reply.id() << ")"
|
||||
INFO_LOG() << "Got create reply: " << reply() << "(id=" << reply.id() << ")"
|
||||
<< ", this=" << this
|
||||
<< ", reply.error()=" << reply.error();
|
||||
if (reply.error())
|
||||
ERROR_LOG(m_logger) << "onExplosionClusterModifyReply: Got reply: " << reply() << "(id=" << reply.id() << ")"
|
||||
ERROR_LOG() << "onExplosionClusterModifyReply: Got reply: " << reply() << "(id=" << reply.id() << ")"
|
||||
<< " '" << reply.translated() << "'";
|
||||
}
|
||||
|
||||
@@ -114,7 +113,7 @@ void HandlerNasatImpact::nasatImpact(int nasatId, const Core::GeoPosition &pos,
|
||||
return;
|
||||
#endif
|
||||
|
||||
DEBUG_LOG(m_logger) << LOGFUNCTION << " START, nasatId=" << nasatId
|
||||
DEBUG_LOG() << Q_FUNC_INFO << " START, nasatId=" << nasatId
|
||||
<< ", pos=" << pos
|
||||
<< ", flightTimeMsec = " << flightTimeMsec
|
||||
<< ", impactTimeMsec = " << impactTimeMsec;
|
||||
@@ -122,7 +121,7 @@ void HandlerNasatImpact::nasatImpact(int nasatId, const Core::GeoPosition &pos,
|
||||
const auto participants = m_mainHandler->handlerParticipant()->participantsForNasatId(nasatId);
|
||||
if (participants.isEmpty())
|
||||
{
|
||||
WARNING_LOG(m_logger) << "Can not find a valid participant for nasat aircraft with id " << nasatId;
|
||||
WARNING_LOG() << "Can not find a valid participant for nasat aircraft with id " << nasatId;
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -146,7 +145,7 @@ void HandlerNasatImpact::nasatImpact(int nasatId, const Core::GeoPosition &pos,
|
||||
if (m_logger.isDebugEnabled())
|
||||
{
|
||||
const Core::GeoPosition &nasatPos = m_mainHandler->handlerParticipant()->nasatPosition(nasatId);
|
||||
DEBUG_LOG(m_logger) << LOGFUNCTION << " START, nasatId=" << nasatId
|
||||
DEBUG_LOG() << Q_FUNC_INFO << " START, nasatId=" << nasatId
|
||||
<< ", pos=" << nasatPos
|
||||
<< ", flightTimeMsec = " << flightTimeMsec
|
||||
<< ", impactTimeMsec=" << impactTimeMsec;
|
||||
@@ -192,7 +191,7 @@ void HandlerNasatImpact::nasatImpact(int nasatId, const Core::GeoPosition &pos,
|
||||
|
||||
|
||||
|
||||
DEBUG_LOG(m_logger) << " Sending air support impact: number of participant= " << participants.size();
|
||||
DEBUG_LOG() << " Sending air support impact: number of participant= " << participants.size();
|
||||
for (const NasatAircraftParticipantEx *nap : participants)
|
||||
{
|
||||
|
||||
@@ -206,17 +205,17 @@ void HandlerNasatImpact::nasatImpact(int nasatId, const Core::GeoPosition &pos,
|
||||
|
||||
int success = nap->publisher()->publish(ecCommonModifyRequest, this);
|
||||
if (success)
|
||||
DEBUG_LOG(m_logger) << "Sending air support impact create request: " << ecReq << " to exercise " << nap->exerciseId()
|
||||
DEBUG_LOG() << "Sending air support impact create request: " << ecReq << " to exercise " << nap->exerciseId()
|
||||
<< ", nap=" << nap->participant()
|
||||
<< " -> success = " << success;
|
||||
else
|
||||
ERROR_LOG(m_logger) << "Error on Sending air support impact create request: " << ecReq << " to exercise " << nap->exerciseId()
|
||||
ERROR_LOG() << "Error on Sending air support impact create request: " << ecReq << " to exercise " << nap->exerciseId()
|
||||
<< ", nap=" << nap->participant()
|
||||
<< " -> success = " << success;
|
||||
|
||||
#ifdef NLDEVCTRL_844
|
||||
testing.requestCounter++;
|
||||
INFO_LOG(m_logger) << " requestCounter = " << testing.requestCounter;
|
||||
INFO_LOG() << " requestCounter = " << testing.requestCounter;
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -255,7 +254,7 @@ void HandlerNasatImpact::onChargeTypeChanged(const ProjectDataManagement::Charge
|
||||
int nasatId = obj.value(QLatin1String("nasatId")).toInt();
|
||||
if (nasatId == 0)
|
||||
{
|
||||
WARNING_LOG(m_logger) << "Found charge with an invalid property 'nasatId', id: " << ct.id();
|
||||
WARNING_LOG() << "Found charge with an invalid property 'nasatId', id: " << ct.id();
|
||||
return;
|
||||
}
|
||||
m_chargeMapping.insert(nasatId, ct.id());
|
||||
@@ -267,7 +266,7 @@ int HandlerNasatImpact::chargeTypeFromMunitionCode(int nasatChargeCode) const
|
||||
auto it = m_chargeMapping.find(nasatChargeCode);
|
||||
if (it != m_chargeMapping.end())
|
||||
return it.value();
|
||||
WARNING_LOG(m_logger) << "Got unmapped nasat charge code " << nasatChargeCode;
|
||||
WARNING_LOG() << "Got unmapped nasat charge code " << nasatChargeCode;
|
||||
Q_ASSERT(false);
|
||||
return -1;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user