Skip to content

Commit

Permalink
Use globalMatchView in html.cpp
Browse files Browse the repository at this point in the history
In Qt >= 6.5, because using globalMatch with a QStringView is deprecated
in Qt 6.9.
  • Loading branch information
askmeaboutlo0m committed Oct 22, 2024
1 parent 1daa64e commit 7bf2411
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/libclient/utils/html.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,11 @@ QString linkify(const QString &input, const QString &extra)

static const QRegularExpression protore("^[a-zA-Z]{3,}:");

auto matches = linkre.globalMatch(in);
#if QT_VERSION >= QT_VERSION_CHECK(6, 5, 0)
QRegularExpressionMatchIterator matches = linkre.globalMatchView(in);
#else
QRegularExpressionMatchIterator matches = linkre.globalMatch(in);
#endif
QString out;
int pos=0;

Expand Down

0 comments on commit 7bf2411

Please sign in to comment.