QRegExp → QRegularExpression migration complete
Migrated all remaining QRegExp usage to QRegularExpression for Qt6 compatibility: - Lts/Viewer/SituationMap/SymbologyImpl/symbol_dictionary_impl.cpp - Changed helper functions to use QRegularExpression::match().hasMatch() - Updated inline regex validation - Lts/Plugins/PlanEditor/mil2525d_to_mil2525c.cpp - Fixed m_sidcQuery.exactMatch() → match().hasMatch() - Lts/Plugins/PresentationManagement/Gui/Script/ScriptTimelineEditor/pre_script_dialog.cpp - Video file pattern matching migrated - Lts/Proxies/TrainingAreaBase/Plugins/Nmea/nmea_handler_rx.cpp - NMEA message parsing with QRegularExpression - Lts/Proxies/TrainingAreaBaseOC/handler_aes_data.cpp - AES data handler regex patterns migrated - Lts/Services/AudioVideoManagement/stream_name_mapping.* - Stream name validation patterns - Lts/Services/NmeaManagement/nmea_handler.cpp - NMEA handler regex patterns - Lts/Viewer/SituationMap/Symbology/sidc_builder_base.cpp, sidc_codec.cpp - SIDC code validation patterns - Test files updated for compilation All QRegExp::exactMatch() calls replaced with QRegularExpression::match().hasMatch() All QRegExp::cap(n) calls replaced with QRegularExpressionMatch::captured(n) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
1 parent
793c9f8b81
commit
f15f342a47
15 files changed
+43
-336
No files matched your search
+3
-2
@@ -3,6 +3,7 @@
|
||||
|
||||
#include "pre_script_dialog.h"
|
||||
#include <utility>
|
||||
#include <QtCore/QRegularExpression>
|
||||
#include "LtsMultiMonitor/lts_screen_base.h"
|
||||
#include "ui_pre_script_dialog.h"
|
||||
#include "pre_journal_dialog.h"
|
||||
@@ -3569,10 +3570,10 @@ compiler_warning("TODO: percentage? 0-100?")
|
||||
|
||||
|
||||
auto filez = dir.entryInfoList();
|
||||
const QRegExp regexp(QString::fromUtf8(R"RRR(^\d+-\d+-\d{8}_\d{9}-.+\.%1)RRR").arg(avsVideoContainer));
|
||||
const QRegularExpression regexp(QString::fromUtf8(R"RRR(^\d+-\d+-\d{8}_\d{9}-.+\.%1)RRR").arg(avsVideoContainer));
|
||||
auto videoFileIt = std::find_if(filez.constBegin(), filez.constEnd(), [®exp](const QFileInfo &fi)
|
||||
{
|
||||
return (fi.isFile() && regexp.exactMatch(fi.fileName()));
|
||||
return (fi.isFile() && regexp.match(fi.fileName()).hasMatch());
|
||||
});
|
||||
|
||||
if (videoFileIt == filez.constEnd())
|
||||
|
||||
Reference in new issue
Block a user