Replace QRegExp with QRegularExpression

This commit is contained in:
Jonas Kvinge
2020-07-18 04:05:07 +02:00
parent cf5259e218
commit e5b3df41e9
25 changed files with 102 additions and 96 deletions

View File

@@ -36,6 +36,7 @@
#include <QTextCodec>
#include <QDesktopServices>
#include <QCryptographicHash>
#include <QRegularExpression>
#include <QSettings>
#include <QJsonDocument>
#include <QJsonObject>
@@ -501,7 +502,7 @@ void GeniusLyricsProvider::HandleLyricReply(QNetworkReply *reply, const int sear
begin_idx += tag_begin.length();
int end_idx = content.indexOf(tag_end, begin_idx);
lyrics = content.mid(begin_idx, end_idx - begin_idx);
lyrics = lyrics.remove(QRegExp("<[^>]*>"));
lyrics = lyrics.remove(QRegularExpression("<[^>]*>"));
lyrics = lyrics.trimmed();
}