diff --git a/qt6-after/qt6-migrated-legatus/Lts/Application/THP/thp_viewer.cpp b/qt6-after/qt6-migrated-legatus/Lts/Application/THP/thp_viewer.cpp index 532e6093f..f284076f5 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Application/THP/thp_viewer.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Application/THP/thp_viewer.cpp @@ -258,7 +258,7 @@ void ThpViewer::onLinkClicked(const QUrl &url) const QString path = url.path(); const QString lpath = path.toLower(); - // Qt6: QStringRef/QString::splitRef were removed; QStringView::split provides zero-copy access + // Use QStringView for efficient string operations const QStringView ext = QStringView{lpath}.split(QLatin1Char('.')).last(); const QStringView ext2Chars = ext.left(2); diff --git a/qt6-after/qt6-migrated-legatus/Lts/Application/THP/thpwidgets/thp_html_widget.cpp b/qt6-after/qt6-migrated-legatus/Lts/Application/THP/thpwidgets/thp_html_widget.cpp index d6fb08ea5..7bf42d651 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Application/THP/thpwidgets/thp_html_widget.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Application/THP/thpwidgets/thp_html_widget.cpp @@ -32,7 +32,6 @@ public: bool needsToBeOpenedExternally(const QUrl &url) { const QString lpath = url.toString(); - // Qt6: QStringRef/QString::splitRef and QString::midRef were removed; use QStringView const QStringView ext = QStringView{lpath}.split(QLatin1Char('.')).last(); const QStringView ext2Chars = ext.left(2); if (ext == QLatin1String("html") && diff --git a/qt6-after/qt6-migrated-legatus/Lts/Common/LtsPluginManager/lts_plugin_loader.cpp b/qt6-after/qt6-migrated-legatus/Lts/Common/LtsPluginManager/lts_plugin_loader.cpp index 9960dda29..6b1aa4110 100644 --- a/qt6-after/qt6-migrated-legatus/Lts/Common/LtsPluginManager/lts_plugin_loader.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Common/LtsPluginManager/lts_plugin_loader.cpp @@ -295,8 +295,7 @@ bool LtsPluginLoader::loadPlugins(PluginType requestedPluginType, } const QString jsonIid = iid.value().toString().toLower(); // LOWERCASE ! (pun intended) - // Qt6: QStringRef/QString::splitRef were removed; QStringView::split - // provides the same zero-copy tokenization. + // Use QStringView for efficient string operations const QList iidParameters = QStringView{jsonIid}.split(QLatin1Char(':')); DEBUG_LOG(logger) << "Plugin " << absoluteFilePath << " provides iid '" << jsonIid; diff --git a/qt6-after/qt6-migrated-legatus/Lts/DDS/FTC/generic_ftc_impl.h b/qt6-after/qt6-migrated-legatus/Lts/DDS/FTC/generic_ftc_impl.h index aeb2ab06a..1018c90a7 100644 --- a/qt6-after/qt6-migrated-legatus/Lts/DDS/FTC/generic_ftc_impl.h +++ b/qt6-after/qt6-migrated-legatus/Lts/DDS/FTC/generic_ftc_impl.h @@ -430,12 +430,9 @@ private: INFO_LOG(m_logger) << "#receiveReply for " << TopicNameHelper::replyTopicTypeName(); // QueuedConnection to make sure the data is handled in the correct Qt (main) thread request.replySlot.invoke(m_objToInform, Qt::QueuedConnection, - // Qt6: QMetaMethod::invoke takes QMetaMethodArgument; pass the - // registered topic type name like Q_ARG does, but with the - // runtime name (ReplyTopic is a template parameter). QtPrivate::Invoke::argument(TopicNameHelper::replyTopicTypeName(), reply.data()), Q_ARG(int, request.uniqueId), - Q_ARG(bool, !inProgress)); // finished yes/no + Q_ARG(bool, !inProgress)); } else { diff --git a/qt6-after/qt6-migrated-legatus/Lts/Plugins/InfrastructureManagement/Shared/ism_mounting_point.cpp b/qt6-after/qt6-migrated-legatus/Lts/Plugins/InfrastructureManagement/Shared/ism_mounting_point.cpp index c41761092..a124a1662 100644 --- a/qt6-after/qt6-migrated-legatus/Lts/Plugins/InfrastructureManagement/Shared/ism_mounting_point.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Plugins/InfrastructureManagement/Shared/ism_mounting_point.cpp @@ -121,12 +121,12 @@ void MountingPoint::init() { } QString MountingPoint::name() const { - // Qt6: legacy codegen exposed name() as a method; new codegen exposes 'name' as a public member. + // codegen exposes 'name' as public member return QString::fromStdString(m_data.name); } QString MountingPoint::fileName() const { - // Qt6: legacy codegen exposed name() as a method; new codegen exposes 'name' as a public member. + // codegen exposes 'name' as public member return QString::fromStdString(m_data.name); } diff --git a/qt6-after/qt6-migrated-legatus/Lts/Proxies/Buildings/BuildingControlUnit/VWM/vwm_api.cpp b/qt6-after/qt6-migrated-legatus/Lts/Proxies/Buildings/BuildingControlUnit/VWM/vwm_api.cpp index 6c1b28f72..228766c95 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Proxies/Buildings/BuildingControlUnit/VWM/vwm_api.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Proxies/Buildings/BuildingControlUnit/VWM/vwm_api.cpp @@ -33,7 +33,7 @@ namespace VWM namespace { // Ensure QPoint3D meta-type is registered for queued connections -// Qt6: Q_DECLARE_METATYPE is sufficient, no need for qRegisterMetaTypeStreamOperators +// Q_DECLARE_METATYPE is sufficient for custom types static const bool point3dRegistered = []() { return true; }(); diff --git a/qt6-after/qt6-migrated-legatus/Lts/Services/AudioVideoManagement/av_socket.cpp b/qt6-after/qt6-migrated-legatus/Lts/Services/AudioVideoManagement/av_socket.cpp index 724b4bed2..d405c0347 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Services/AudioVideoManagement/av_socket.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Services/AudioVideoManagement/av_socket.cpp @@ -104,8 +104,7 @@ void AVSocket::onConnectToAVS() this, &AVSocket::onDisconnected); connect(m_avsSocket, &QTcpSocket::connected, this, [this] {m_bErrorInTcpComWarnedOnce = false;}); - // Qt6: QAbstractSocket::error() (the getter/signal overload pair) was - // replaced by the errorOccurred signal. + // errorOccurred signal replaces error() getter/signal connect(m_avsSocket, &QAbstractSocket::errorOccurred, this, &AVSocket::onError); connect(m_avsSocket, &QTcpSocket::readyRead, diff --git a/qt6-after/qt6-migrated-legatus/Lts/Services/InfrastructureManagement/handler_main_structure_element.cpp b/qt6-after/qt6-migrated-legatus/Lts/Services/InfrastructureManagement/handler_main_structure_element.cpp index e61b2d70e..77a58681c 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Services/InfrastructureManagement/handler_main_structure_element.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Services/InfrastructureManagement/handler_main_structure_element.cpp @@ -94,7 +94,6 @@ bool HandlerMainStructureElement::init() } // add structure elements to global map for lookup (e.g. in 'add Footprints to MSE objects') - // Qt6: QMap::unite removed -> merge manually (unite semantics: overwrite existing keys) for (ObjectMainStructureElement *objMse : std::as_const(m_objectMainStructureElementMap)) { const auto &seMap = objMse->getStructureElements(); diff --git a/qt6-after/qt6-migrated-legatus/Lts/Services/WarehouseGuez/WsBaseDataInterface/data_manager.cpp b/qt6-after/qt6-migrated-legatus/Lts/Services/WarehouseGuez/WsBaseDataInterface/data_manager.cpp index 47e17cc9e..db70b2bad 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Services/WarehouseGuez/WsBaseDataInterface/data_manager.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Services/WarehouseGuez/WsBaseDataInterface/data_manager.cpp @@ -487,8 +487,7 @@ void DataManager::onNotification(const QString &name, QSqlDriver::NotificationSo const QString triggerNameEx0 = triggerName(0); if (name.contains(triggerNameEx0)) { - // Qt6: QStringRef removed; QString::mid returns a QString with the - // same substring semantics. + // Extract name after trigger prefix QString name_ = name.mid(triggerNameEx0.size() + 1); int exerciseId = name_.toInt(); int participantId = payload.toInt(); diff --git a/qt6-after/qt6-migrated-legatus/Lts/Tools/Adler/WebSocketSimulator/awss_base_layout.cpp b/qt6-after/qt6-migrated-legatus/Lts/Tools/Adler/WebSocketSimulator/awss_base_layout.cpp index 9ae054763..c233bb67e 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Tools/Adler/WebSocketSimulator/awss_base_layout.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Tools/Adler/WebSocketSimulator/awss_base_layout.cpp @@ -17,7 +17,7 @@ //other #include "awss_websocket_interface.h" -#include // Qt6: QAction moved from QtWidgets to QtGui +#include // QAction moved to QtGui #include namespace AdlerWebSocketSimulator { diff --git a/qt6-after/qt6-migrated-legatus/Lts/Tools/DataSampleReceiver/main.cpp b/qt6-after/qt6-migrated-legatus/Lts/Tools/DataSampleReceiver/main.cpp index 78dd92fd3..fb9378e5d 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Tools/DataSampleReceiver/main.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Tools/DataSampleReceiver/main.cpp @@ -30,7 +30,6 @@ static QVector getAvailableTopicTypes() // get top return false; QMap topics = typePlugin->getDataTopics(); - // Qt6: QMap::unite removed; insert() keeps the same "existing keys win" semantics topics.insert(typePlugin->getFunctionTopics()); QMap::iterator it = topics.begin(); @@ -72,7 +71,6 @@ public: return availDataTopics; // Convert list of DoTypes, separated by comma (given by user) - // Qt6: QStringRef/QString::splitRef removed; QStringView::split provides the same tokenization const QString doTypeStr = value(QLatin1String("t")); const QList strList = QStringView{doTypeStr}.split(QLatin1Char(','), Qt::SkipEmptyParts); diff --git a/qt6-after/qt6-migrated-legatus/Lts/Tools/LogViewer/logviewtableview.cpp b/qt6-after/qt6-migrated-legatus/Lts/Tools/LogViewer/logviewtableview.cpp index c3f5e8700..701711b65 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Tools/LogViewer/logviewtableview.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Tools/LogViewer/logviewtableview.cpp @@ -10,7 +10,7 @@ #include "logviewtableview.h" #include "logviewtablemodel.h" -#include // Qt6: QAction moved from QtWidgets to QtGui +#include // QAction moved to QtGui #include #include #include diff --git a/qt6-after/qt6-migrated-legatus/Lts/Tools/ProjectSettingsEditor/main_window.cpp b/qt6-after/qt6-migrated-legatus/Lts/Tools/ProjectSettingsEditor/main_window.cpp index a263ecea5..d3168227a 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Tools/ProjectSettingsEditor/main_window.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Tools/ProjectSettingsEditor/main_window.cpp @@ -13,7 +13,7 @@ #include -#include // Qt6: QAction moved from QtWidgets to QtGui +#include // QAction moved to QtGui #include #include #include diff --git a/qt6-after/qt6-migrated-legatus/Lts/Tools/TextEditorTest/textedit.cpp b/qt6-after/qt6-migrated-legatus/Lts/Tools/TextEditorTest/textedit.cpp index 7c0dc3200..6d879fdd8 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Tools/TextEditorTest/textedit.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Tools/TextEditorTest/textedit.cpp @@ -367,7 +367,7 @@ bool TextEdit::load(const QString &f) return false; QByteArray data = file.readAll(); - // Qt6: QTextCodec/Qt::codecForHtml removed; decode as UTF-8 + // QTextCodec removed in Qt6; use UTF-8 QString str = QString::fromUtf8(data); if (Qt::mightBeRichText(str)) { QUrl baseUrl = (f.front() == QLatin1Char(':') ? QUrl(f) : QUrl::fromLocalFile(f)).adjusted(QUrl::RemoveFilename); diff --git a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/FunctionDialog/function_dialog.cpp b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/FunctionDialog/function_dialog.cpp index a2ab8482e..9692dbb51 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/FunctionDialog/function_dialog.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/FunctionDialog/function_dialog.cpp @@ -2661,7 +2661,7 @@ void FunctionDialog::onRubberbandApply(RB::RubberbandBase *rubberband) for (const auto &bufferPoint : qAsConst(bufferVertexList)) { posCont << Point3D::fromQPointF(bufferPoint); - qDebug() << LOGFUNCTION << "buffer coordinate : " << bufferPoint ; // Qt6: fixed/qSetRealNumberPrecision removed + qDebug() << LOGFUNCTION << "buffer coordinate : " << bufferPoint; } bufferPolygon->setPositionsTranslated(posCont); // use map coordinates to print the coordinate values diff --git a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/GraphicalObjects/graphical_object_renderer_attributes.cpp b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/GraphicalObjects/graphical_object_renderer_attributes.cpp index 6a8cd81e1..5076eb991 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/GraphicalObjects/graphical_object_renderer_attributes.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/GraphicalObjects/graphical_object_renderer_attributes.cpp @@ -103,7 +103,7 @@ bool GraphicalObjectRendererAttributes::updateViewImpl() if (m_logger.isDebugEnabled()) qCritical() << " debugInfo='" << m_debugInfo << "'" << ", QVariantMap before unite " << cur; - // Qt6: QMap::unite() removed; insert only the keys not already present (unite semantics). + // Insert only missing keys (QMap::unite() removed in Qt6) const QVariantMap otherAttrs = m_attributeMap.value(); for (auto it = otherAttrs.constBegin(); it != otherAttrs.constEnd(); ++it) if (!cur.contains(it.key())) diff --git a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/MapImpl/map_impl.cpp b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/MapImpl/map_impl.cpp index af518f04f..03efed036 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/MapImpl/map_impl.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/MapImpl/map_impl.cpp @@ -137,8 +137,8 @@ #include #include -#include // Qt6: QPageLayout::Orientation -#include // Qt6: QEnterEvent (QWidget::enterEvent(QEnterEvent*)) +#include // For QPageLayout::Orientation +#include // For QEnterEvent #include // 300: exportImageAsync() -> QFuture #include // 300: observe the export QFuture #include @@ -206,7 +206,7 @@ public: m_iconOnHover = icon; } - // Qt6: QWidget::enterEvent takes QEnterEvent* (leaveEvent stays QEvent*) + // QWidget::enterEvent takes QEnterEvent* in Qt6 void enterEvent(QEnterEvent *e) override { setIcon(m_iconOnHover); @@ -5686,7 +5686,7 @@ void MapImpl::finishToPdf(const QImage &image, printer.setDocName(title); - const QSizeF pageSize = printer.paperRect(QPrinter::Point).size(); // Qt6: paperRect() now requires a Unit + const QSizeF pageSize = printer.paperRect(QPrinter::Point).size(); // paperRect() requires Unit parameter DEBUG_LOG(m_logger) << LOGFUNCTION << " pageSize=" << pageSize; const QSizeF drawingSize = pageSize - QSizeF(2 * marginInt, 2 * marginInt) * 1.5; diff --git a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyGui/base_symbol_lookup_widget.cpp b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyGui/base_symbol_lookup_widget.cpp index f745a763c..ee479029c 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyGui/base_symbol_lookup_widget.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyGui/base_symbol_lookup_widget.cpp @@ -28,7 +28,7 @@ #include #include -// Qt6: QDesktopWidget removed (was unused here) +// QDesktopWidget removed in Qt6 #include #include #include diff --git a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyGui/symbol_modification_widget.cpp b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyGui/symbol_modification_widget.cpp index e989b9404..9bbe79abd 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyGui/symbol_modification_widget.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyGui/symbol_modification_widget.cpp @@ -696,8 +696,7 @@ void SymbolModificationWidget::buildFieldModifierTab(QWidget *widget) connect(m_internal->m_fieldTable, &QTableView::clicked, this, &SymbolModificationWidget::onFieldItemActived); connect(m_internal->m_fieldTable, &QTableView::activated, this, &SymbolModificationWidget::onFieldItemActived); - // Qt6: QComboBox::activated(const QString&) removed -> use the activated(int) overload and - // map the index to its item text (the slot expects the field-title string). + // Connect to activated signal with index parameter connect(m_internal->m_cbFieldTitle, &QComboBox::activated, this, [this](int index){ onSetFieldTitle(m_internal->m_cbFieldTitle->itemText(index)); }); diff --git a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/base_symbol_model.cpp b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/base_symbol_model.cpp index cd0f9e698..41d7f883a 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/base_symbol_model.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/base_symbol_model.cpp @@ -163,7 +163,7 @@ QString BaseSymbolItem::symbolSet() { if (m_symbolSet.isEmpty()) { - SidcDefinitions::SymbolSet symbolSet = SidcDefinitions::castToSymbolSet(m_symbolProperties.originalKey().left(2).toUInt()); // Qt6: leftRef(2) removed + SidcDefinitions::SymbolSet symbolSet = SidcDefinitions::castToSymbolSet(m_symbolProperties.originalKey().left(2).toUInt()); m_symbolSet = QString(QStringLiteral("%1 - ")).arg(static_cast(symbolSet)) + AdvancedSymbology::SidcDefinitions::toString(symbolSet); } return m_symbolSet; @@ -171,7 +171,7 @@ QString BaseSymbolItem::symbolSet() int BaseSymbolItem::symbolSetAsInt() { - return static_cast(SidcDefinitions::castToSymbolSet(m_symbolProperties.originalKey().left(2).toUInt())); // Qt6: leftRef(2) removed + return static_cast(SidcDefinitions::castToSymbolSet(m_symbolProperties.originalKey().left(2).toUInt())); } diff --git a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/esri_dictionary_processor.cpp b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/esri_dictionary_processor.cpp index 4475ced5d..3b8162f9a 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/esri_dictionary_processor.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/esri_dictionary_processor.cpp @@ -125,9 +125,7 @@ void EsriDictionaryProcessor::startBaseSymbolCodeToPropertyTable() { TRACE_LOG(m_logger) << LOGFUNCTION << " START"; - // A-sync: - // (slot is a pure virtual method) - // Qt6: QtConcurrent::run(context, &method) is gone; pass the member fn first, then the receiver. + // QtConcurrent::run member function syntax changed in Qt6 m_baseSymbolCodeToSymbolPropertyTableWatcher = QtConcurrent::run(&EsriDictionaryProcessor::processBaseSymbolCodeToPropertyTable, this); @@ -140,9 +138,7 @@ void EsriDictionaryProcessor::startModifierTable() { TRACE_LOG(m_logger) << LOGFUNCTION << " START"; - // A-sync: - // (slot is a pure virtual method) - // Qt6: QtConcurrent::run(context, &method) is gone; pass the member fn first, then the receiver. + // QtConcurrent::run member function syntax changed in Qt6 m_modifierTableWatcher = QtConcurrent::run(&EsriDictionaryProcessor::processModifierTable, this); // Sync: // processModifierTable(); diff --git a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/esri_dictionary_processor_app6d.cpp b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/esri_dictionary_processor_app6d.cpp index ab71abb78..e0ce27986 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/esri_dictionary_processor_app6d.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/esri_dictionary_processor_app6d.cpp @@ -317,7 +317,7 @@ bool EsriDictionaryProcessorApp6D::processBaseSymbolCodeToPropertyTable() symProps.setSidc(SidcCodec::encodeBaseSymbolCode(m_baseSymbolCodeToSymbolPropertyTable.symbologyType(), key8)); // retrieve GeometryType const QString cat = resultItem.category(); - const QStringList &slCategory = cat.split(QLatin1Char(':')); // Qt6: split() returns QStringList + const QStringList &slCategory = cat.split(QLatin1Char(':')); if (!slCategory.isEmpty()) { const QString geometryStr = slCategory.last().trimmed(); @@ -337,7 +337,7 @@ bool EsriDictionaryProcessorApp6D::processBaseSymbolCodeToPropertyTable() DEBUG_LOG(m_logger) << LOGFUNCTION << " XXXXXXXXX GeometryType:" << " key8='" << key8 << "'" << " originalKey='" << originalKey << "'" - << "' slLast='" << slCategory.last() << "'" // Qt6: QString has no toString() + << "' slLast='" << slCategory.last() << "'" << " geoType= " << symProps.geometryType(); // check for gct_-String: @@ -440,9 +440,9 @@ bool EsriDictionaryProcessorApp6D::processModifierTable() } modData.m_symbolSet = symbolSetEnum; - modData.m_modifierSector = originalKey.mid(4, 1).toUInt(); // Qt6: midRef removed + modData.m_modifierSector = originalKey.mid(4, 1).toUInt(); modData.m_modifierValue = originalKey.mid(2, 2).toUInt(); - modData.m_modifierName = (sl.size() == 2) ? sl.last() : resultItem.name(); // Qt6: QString has no toString() + modData.m_modifierName = (sl.size() == 2) ? sl.last() : resultItem.name(); m_modifierTable[originalKey] = modData; diff --git a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/esri_dictionary_processor_mil2525d.cpp b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/esri_dictionary_processor_mil2525d.cpp index 92d28c460..7840be844 100755 --- a/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/esri_dictionary_processor_mil2525d.cpp +++ b/qt6-after/qt6-migrated-legatus/Lts/Viewer/SituationMap/SymbologyImpl/esri_dictionary_processor_mil2525d.cpp @@ -113,7 +113,7 @@ bool EsriDictionaryProcessorMil2525D::searchResultIsValid(const QHash layerNames; layerNames << QStringLiteral("BaseMap") << QStringLiteral("Overlay1") diff --git a/qt6-after/qt6-migrated-legatus/tests/test_mathutils.cpp b/qt6-after/qt6-migrated-legatus/tests/test_mathutils.cpp index c709eae89..8952fee6c 100644 --- a/qt6-after/qt6-migrated-legatus/tests/test_mathutils.cpp +++ b/qt6-after/qt6-migrated-legatus/tests/test_mathutils.cpp @@ -71,7 +71,6 @@ TEST(MathUtilsTest, Polygon_Area_Calculation) // Test MathUtils Qt6 QList/QVector compatibility TEST(MathUtilsTest, Qt6_List_Vector_Compatibility) { - // Qt6: QList and QVector are identical // This test verifies that ambiguous overloads are resolved QList list = {1.0, 2.0, 3.0, 4.0, 5.0}; diff --git a/qt6-after/qt6-migrated-legatus/tests/test_qt6_api_migrations.cpp b/qt6-after/qt6-migrated-legatus/tests/test_qt6_api_migrations.cpp index bfab63cdb..31f8a6e79 100644 --- a/qt6-after/qt6-migrated-legatus/tests/test_qt6_api_migrations.cpp +++ b/qt6-after/qt6-migrated-legatus/tests/test_qt6_api_migrations.cpp @@ -25,7 +25,7 @@ TEST(Qt6ApiTest, QStringView_Sliced) QString testString = QStringLiteral("Hello World"); QStringView view(testString); - // Qt6: slice() -> sliced() + // QBitArray::sliced() in Qt6 (was slice()) QStringView subView = view.sliced(0, 5); EXPECT_EQ(subView.toString(), QStringLiteral("Hello")); @@ -61,7 +61,6 @@ TEST(Qt6ApiTest, QFuture_Continuation) return 42; }); - // Qt6: QFuture supports .then() continuations QFuture continued = future.then([](QFuture result) { return QString::number(result.result()); }); @@ -73,7 +72,7 @@ TEST(Qt6ApiTest, QFuture_Continuation) // Test Qt::MiddleButton enum (Qt6 replacement for Qt::MidButton) TEST(Qt6ApiTest, Qt_MiddleButton_Enum) { - // Qt6: Qt::MidButton -> Qt::MiddleButton + // Qt::MiddleButton in Qt6 (was MidButton) Qt::MouseButton middleBtn = Qt::MiddleButton; EXPECT_EQ(middleBtn, Qt::MiddleButton); EXPECT_NE(middleBtn, Qt::LeftButton); @@ -88,7 +87,7 @@ TEST(Qt6ApiTest, QVariantMap_Iteration) map1.insert(QStringLiteral("key2"), 2); QVariantMap map2; - // Qt6: Replace unite() with iterate/insert pattern + // QMap::unite() removed in Qt6 for (auto it = map1.begin(); it != map1.end(); ++it) { map2.insert(it.key(), it.value()); @@ -103,8 +102,7 @@ TEST(Qt6ApiTest, QVariantMap_Iteration) TEST(Qt6ApiTest, QTouchEvent_API) { // This test verifies the API exists - actual touch testing requires GUI - // Qt6: touchPoints() -> points() - // Qt6: QEventPoint::screenPos() -> globalPosition() + // QTouchEvent::points() and QEventPoint::globalPosition() in Qt6 // Create a mock test - in real code, QTouchEvent is created by system // We verify the types compile correctly @@ -121,7 +119,7 @@ TEST(Qt6ApiTest, QTouchEvent_API) // Test QMouseEvent position API (Qt6) TEST(Qt6ApiTest, QMouseEvent_Position_API) { - // Qt6: event.x()/y() -> event.position().x()/y() + // QMouseEvent::position() in Qt6 (was x()/y()) // Create a mouse event with Qt6 API QMouseEvent event(QEvent::MouseButtonPress, QPointF(100.0, 200.0), // globalPos @@ -142,7 +140,7 @@ TEST(Qt6ApiTest, QMouseEvent_Position_API) // Test QWheelEvent position API (Qt6) TEST(Qt6ApiTest, QWheelEvent_Position_API) { - // Qt6: event.x()/y() -> event.position().x()/y() + // QWheelEvent::position() in Qt6 (was x()/y()) QWheelEvent event(QPointF(100.0, 200.0), // pos QPointF(100.0, 200.0), // globalPos QPoint(0, 0), // pixelDelta diff --git a/qt6-after/qt6-migrated-legatus/tests/test_rubberbands.cpp b/qt6-after/qt6-migrated-legatus/tests/test_rubberbands.cpp index 52e39c86f..5f45d0e16 100644 --- a/qt6-after/qt6-migrated-legatus/tests/test_rubberbands.cpp +++ b/qt6-after/qt6-migrated-legatus/tests/test_rubberbands.cpp @@ -64,7 +64,6 @@ TEST(RubberbandsTest, QTouchEvent_API_Qt6) // Test Rubberbands QFuture continuation pattern TEST(RubberbandsTest, QFuture_Continuation_Pattern) { - // Qt6: QFuture supports .then() continuations // This pattern is used in Rubberbands for async operations QFuture future = QtConcurrent::run([]() { @@ -156,7 +155,6 @@ TEST(RubberbandsTest, Async_Operation_Simulation) // Test Rubberbands Qt6 container compatibility TEST(RubberbandsTest, Qt6_Container_Compatibility) { - // Qt6: QList and QVector are identical QList points; points.append(QPointF(0, 0)); diff --git a/qt6-after/qt6-migrated-legatus/tests/test_symbologyimpl.cpp b/qt6-after/qt6-migrated-legatus/tests/test_symbologyimpl.cpp index d75ba6b33..3dfe9f59c 100644 --- a/qt6-after/qt6-migrated-legatus/tests/test_symbologyimpl.cpp +++ b/qt6-after/qt6-migrated-legatus/tests/test_symbologyimpl.cpp @@ -71,14 +71,13 @@ TEST(SymbologyImplTest, SymbolDictionary_BasicOperations) // Test SymbologyImpl Qt6 QFuture continuation pattern TEST(SymbologyImplTest, Qt6_QFuture_Continuation_Pattern) { - // Qt6: QFuture continuation pattern // This test verifies the pattern used in symbol_dictionary_impl.cpp QFuture future = QtConcurrent::run([]() { return 42; // Simulate symbol loading count }); - // Qt6: Use .then() for continuations + // QFuture::then() for continuations in Qt6 QFuture continued = future.then([](QFuture result) { int count = result.result(); return QStringLiteral("Loaded %1 symbols").arg(count); @@ -105,7 +104,6 @@ TEST(SymbologyImplTest, Qt6_API_Compatibility) EXPECT_EQ(symbolNames.size(), 3); - // Qt6: QList and QVector are identical QVector symbolVector = symbolNames; EXPECT_EQ(symbolVector.size(), 3); diff --git a/qt6-after/qt6-migrated-legatus/tests/test_viewshed3d.cpp b/qt6-after/qt6-migrated-legatus/tests/test_viewshed3d.cpp index 9c0640439..c246d83c5 100644 --- a/qt6-after/qt6-migrated-legatus/tests/test_viewshed3d.cpp +++ b/qt6-after/qt6-migrated-legatus/tests/test_viewshed3d.cpp @@ -73,7 +73,7 @@ TEST(Viewshed3DTest, ViewshedLocation_BasicOperations) // Test Viewshed3D Qt6 QMouseEvent API TEST(Viewshed3DTest, Qt6_QMouseEvent_API) { - // Qt6: QMouseEvent globalPosition() returns QPointF + // QMouseEvent::globalPosition() returns QPointF in Qt6 // This test verifies the pattern used in ViewshedLocation.cpp // Create a mock mouse event position @@ -86,7 +86,7 @@ TEST(Viewshed3DTest, Qt6_QMouseEvent_API) EXPECT_DOUBLE_EQ(localPos.x(), 50.0); EXPECT_DOUBLE_EQ(localPos.y(), 75.0); - // Qt6: Use globalPosition() instead of globalX()/globalY() + // Use globalPosition() in Qt6 // In actual code: event->globalPosition().x(), event->globalPosition().y() double globalX = globalPos.x(); double globalY = globalPos.y(); @@ -98,7 +98,7 @@ TEST(Viewshed3DTest, Qt6_QMouseEvent_API) // Test Viewshed3D Qt6 QWheelEvent API TEST(Viewshed3DTest, Qt6_QWheelEvent_API) { - // Qt6: QWheelEvent position() and globalPosition() return QPointF + // QWheelEvent position()/globalPosition() return QPointF // This test verifies the pattern used in ViewshedLocation.cpp QPointF position(150.0, 250.0); @@ -110,7 +110,7 @@ TEST(Viewshed3DTest, Qt6_QWheelEvent_API) EXPECT_DOUBLE_EQ(globalPosition.x(), 200.0); EXPECT_DOUBLE_EQ(globalPosition.y(), 300.0); - // Qt6: Use position() instead of x()/y() + // Use position() in Qt6 double posX = position.x(); double posY = position.y(); @@ -121,7 +121,7 @@ TEST(Viewshed3DTest, Qt6_QWheelEvent_API) // Test Viewshed3D Qt6 QTouchEvent API TEST(Viewshed3DTest, Qt6_QTouchEvent_API) { - // Qt6: QTouchEvent points() returns list of touch points + // QTouchEvent::points() returns list in Qt6 // This test verifies the pattern used in ViewshedLocation.cpp // Simulate touch points @@ -138,7 +138,7 @@ TEST(Viewshed3DTest, Qt6_QTouchEvent_API) EXPECT_EQ(touchPoints.size(), 2); - // Qt6: Use points() to access touch points + // Access touch points via points() in Qt6 // In actual code: for (const auto& point : event->points()) for (const auto& point : touchPoints) { @@ -156,7 +156,6 @@ TEST(Viewshed3DTest, Qt6_QTouchEvent_API) // Test Viewshed3D Qt6 container operations TEST(Viewshed3DTest, Qt6_Container_Operations) { - // Qt6: QList and QVector are identical QList elevations; elevations << 100.0 << 200.0 << 300.0 << 400.0 << 500.0; diff --git a/qt6-after/qt6-migrated-legatus/tests/test_z_proxies_integration.cpp b/qt6-after/qt6-migrated-legatus/tests/test_z_proxies_integration.cpp index 9a0d101e0..d125dfd95 100644 --- a/qt6-after/qt6-migrated-legatus/tests/test_z_proxies_integration.cpp +++ b/qt6-after/qt6-migrated-legatus/tests/test_z_proxies_integration.cpp @@ -170,8 +170,8 @@ TEST(ZProxiesIntegration, Qt6OptionalModules) // Verify that optional Qt6 modules are available // These modules are installed via aqtinstall and apt - bool multimediaAvailable = true; // Qt6::Multimedia - bool svgAvailable = true; // Qt6::Svg + bool multimediaAvailable = true; // Qt6 Multimedia module + bool svgAvailable = true; // Qt6 Svg module EXPECT_TRUE(multimediaAvailable) << "Qt6::Multimedia should be available"; EXPECT_TRUE(svgAvailable) << "Qt6::Svg should be available";