aboutsummaryrefslogtreecommitdiff
path: root/src/plugins/General/scrobbler
diff options
context:
space:
mode:
authortrialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38>2019-07-02 21:12:41 +0000
committertrialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38>2019-07-02 21:12:41 +0000
commitc75694c1cd54c2dda0e4a3a522baf1fcbcdcd7b1 (patch)
treef518aa7d889c8ba190a8dd074d92777b8173ca38 /src/plugins/General/scrobbler
parentae9b41a535a0d86968d8ec68ba1be4bf203a2176 (diff)
downloadqmmp-c75694c1cd54c2dda0e4a3a522baf1fcbcdcd7b1.tar.gz
qmmp-c75694c1cd54c2dda0e4a3a522baf1fcbcdcd7b1.tar.bz2
qmmp-c75694c1cd54c2dda0e4a3a522baf1fcbcdcd7b1.zip
listenbrainz plugin implementation
git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@8981 90c681e8-e032-0410-971d-27865f9a5e38
Diffstat (limited to 'src/plugins/General/scrobbler')
-rw-r--r--src/plugins/General/scrobbler/scrobbler.cpp2
-rw-r--r--src/plugins/General/scrobbler/scrobbler.h2
-rw-r--r--src/plugins/General/scrobbler/scrobblercache.cpp6
-rw-r--r--src/plugins/General/scrobbler/scrobblercache.h4
4 files changed, 7 insertions, 7 deletions
diff --git a/src/plugins/General/scrobbler/scrobbler.cpp b/src/plugins/General/scrobbler/scrobbler.cpp
index f8f367e45..d9532f987 100644
--- a/src/plugins/General/scrobbler/scrobbler.cpp
+++ b/src/plugins/General/scrobbler/scrobbler.cpp
@@ -85,7 +85,7 @@ Scrobbler::Scrobbler(const QString &scrobblerUrl, const QString &name, QObject *
m_scrobblerUrl = scrobblerUrl;
m_name = name;
m_time = new QElapsedTimer();
- m_cache = new ScrobblerCache(Qmmp::configDir() +"/scrobbler_"+name+".cache");
+ m_cache = new ListenCache(Qmmp::configDir() +"/scrobbler_"+name+".cache");
m_ua = QString("qmmp-plugins/%1").arg(Qmmp::strVersion().toLower()).toLatin1();
m_http = new QNetworkAccessManager(this);
m_core = SoundCore::instance();
diff --git a/src/plugins/General/scrobbler/scrobbler.h b/src/plugins/General/scrobbler/scrobbler.h
index ad3e1d56e..b4f727424 100644
--- a/src/plugins/General/scrobbler/scrobbler.h
+++ b/src/plugins/General/scrobbler/scrobbler.h
@@ -79,7 +79,7 @@ private:
SoundCore *m_core;
QNetworkReply *m_submitReply = nullptr, *m_notificationReply = nullptr;
QElapsedTimer *m_time;
- ScrobblerCache *m_cache;
+ ListenCache *m_cache;
QString m_scrobblerUrl, m_name;
Qmmp::State m_previousState = Qmmp::Stopped;
qint64 m_elapsed = 0;
diff --git a/src/plugins/General/scrobbler/scrobblercache.cpp b/src/plugins/General/scrobbler/scrobblercache.cpp
index 841c8c48f..05319e2a3 100644
--- a/src/plugins/General/scrobbler/scrobblercache.cpp
+++ b/src/plugins/General/scrobbler/scrobblercache.cpp
@@ -61,12 +61,12 @@ uint SongInfo::timeStamp() const
return m_start_ts;
}
-ScrobblerCache::ScrobblerCache(const QString &filePath)
+ListenCache::ListenCache(const QString &filePath)
{
m_filePath = filePath;
}
-QList<SongInfo> ScrobblerCache::load()
+QList<SongInfo> ListenCache::load()
{
QList<SongInfo> songs;
int s = 0;
@@ -115,7 +115,7 @@ QList<SongInfo> ScrobblerCache::load()
return songs;
}
-void ScrobblerCache::save(const QList<SongInfo> &songs)
+void ListenCache::save(const QList<SongInfo> &songs)
{
QFile file(m_filePath);
if (songs.isEmpty())
diff --git a/src/plugins/General/scrobbler/scrobblercache.h b/src/plugins/General/scrobbler/scrobblercache.h
index 819d1fa96..1bfc3c502 100644
--- a/src/plugins/General/scrobbler/scrobblercache.h
+++ b/src/plugins/General/scrobbler/scrobblercache.h
@@ -51,10 +51,10 @@ private:
/**
@author Ilya Kotov <forkotov02@ya.ru>
*/
-class ScrobblerCache
+class ListenCache
{
public:
- explicit ScrobblerCache(const QString &filePath);
+ explicit ListenCache(const QString &filePath);
QList<SongInfo> load();
void save(const QList<SongInfo> &songs);