diff options
| author | trialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38> | 2019-11-04 13:25:05 +0000 |
|---|---|---|
| committer | trialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38> | 2019-11-04 13:25:05 +0000 |
| commit | 74ec7eeee3de7e5b1a7f07206da65b604356f9be (patch) | |
| tree | 13a529acdc009d84bf8edb9621f574f6553b5365 /src/plugins/General/lyrics/lyricsprovider.cpp | |
| parent | a52f165675d244a4e01c583ec44fd40a1cc127d1 (diff) | |
| download | qmmp-74ec7eeee3de7e5b1a7f07206da65b604356f9be.tar.gz qmmp-74ec7eeee3de7e5b1a7f07206da65b604356f9be.tar.bz2 qmmp-74ec7eeee3de7e5b1a7f07206da65b604356f9be.zip | |
lyrics: added settings dialog, fixed remaining issues
git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@9093 90c681e8-e032-0410-971d-27865f9a5e38
Diffstat (limited to 'src/plugins/General/lyrics/lyricsprovider.cpp')
| -rw-r--r-- | src/plugins/General/lyrics/lyricsprovider.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/plugins/General/lyrics/lyricsprovider.cpp b/src/plugins/General/lyrics/lyricsprovider.cpp index 4dae451dd..755e1ba06 100644 --- a/src/plugins/General/lyrics/lyricsprovider.cpp +++ b/src/plugins/General/lyrics/lyricsprovider.cpp @@ -101,6 +101,9 @@ QString LyricsProvider::format(const QByteArray &data, const TrackInfo &track) c return QString(); } + if(m_skipRules) + return content; + const QMap<QString, QString> replaceMap = generateReplaceMap(track); for(const Rule &rule : qAsConst(m_extractRules)) @@ -157,6 +160,11 @@ const QString &LyricsProvider::name() const return m_name; } +void LyricsProvider::skipRules(bool skip) +{ + m_skipRules = skip; +} + QString LyricsProvider::fixCase(const QString &title) const { QString out; @@ -201,7 +209,6 @@ QString LyricsProvider::extract(const QString &content, const Rule &rule) const for(const Item &item : qAsConst(rule)) { - if(!item.url.isEmpty()) { QString url = item.url; |
