Use a QTimer for writing scrobbler cache

This commit is contained in:
Jonas Kvinge
2021-01-30 21:48:45 +01:00
parent 477ee14b6d
commit cc6c7430d4
2 changed files with 18 additions and 3 deletions

View File

@@ -32,6 +32,7 @@
#include "scrobblercacheitem.h"
class QTimer;
class Song;
class ScrobblerCache : public QObject {
@@ -56,6 +57,7 @@ class ScrobblerCache : public QObject {
void WriteCache();
private:
QTimer *timer_flush_;
QString filename_;
bool loaded_;
QHash<quint64, ScrobblerCacheItemPtr> scrobbler_cache_;