From 0a4366a16dfda251a4c2edf619f846cde8ad9f8a Mon Sep 17 00:00:00 2001 From: Samuel Gaist Date: Sun, 2 Dec 2018 14:02:28 +0100 Subject: QQmlNdefRecord: port to QRegularExpression This patch updates the QQmlNdefRecord code to use QRegularExpression in place of QRegExp which is to be considered deprecated. Change-Id: Ibfbab39ca84f9e89d6f6bd2e15000359a4218234 Reviewed-by: Alex Blasche --- src/nfc/qqmlndefrecord.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/nfc/qqmlndefrecord.cpp b/src/nfc/qqmlndefrecord.cpp index a7304f00..bc3667fe 100644 --- a/src/nfc/qqmlndefrecord.cpp +++ b/src/nfc/qqmlndefrecord.cpp @@ -40,7 +40,7 @@ #include "qqmlndefrecord.h" #include -#include +#include #include @@ -219,8 +219,8 @@ QQmlNdefRecord *qNewDeclarativeNdefRecordForNdefRecord(const QNdefRecord &record while (i.hasNext()) { i.next(); - QRegExp ex(i.key()); - if (!ex.exactMatch(urn)) + QRegularExpression rx(QRegularExpression::anchoredPattern(i.key())); + if (!rx.match(urn).hasMatch()) continue; const QMetaObject *metaObject = i.value(); -- cgit v1.2.3