summary refs log tree commit diff
path: root/include/AvatarProvider.h
diff options
context:
space:
mode:
authorKonstantinos Sideris <sideris.konstantin@gmail.com>2018-05-08 18:43:56 +0300
committerKonstantinos Sideris <sideris.konstantin@gmail.com>2018-05-08 18:43:56 +0300
commit4c4ea557b344b035507652cfbc3b616904f958e9 (patch)
treee8e610bfdaebb0ffb3a472f89b699bc3f65852b8 /include/AvatarProvider.h
parentRemove the pseudo deb & rpm packages from releases (diff)
downloadnheko-4c4ea557b344b035507652cfbc3b616904f958e9.tar.xz
Replace shared pointers of MatrixClient with a single instance
Diffstat (limited to 'include/AvatarProvider.h')
-rw-r--r--include/AvatarProvider.h8
1 files changed, 1 insertions, 7 deletions
diff --git a/include/AvatarProvider.h b/include/AvatarProvider.h

index fd5f15c4..af13a577 100644 --- a/include/AvatarProvider.h +++ b/include/AvatarProvider.h
@@ -22,7 +22,6 @@ #include <QSharedPointer> #include <functional> -class MatrixClient; class TimelineItem; class Cache; @@ -31,11 +30,7 @@ class AvatarProvider : public QObject Q_OBJECT public: - static void init(QSharedPointer<MatrixClient> client, QSharedPointer<Cache> cache) - { - client_ = client; - cache_ = cache; - } + static void init(QSharedPointer<Cache> cache) { cache_ = cache; } //! The callback is called with the downloaded avatar for the given user //! or the avatar is downloaded first and then saved for re-use. static void resolve(const QString &room_id, @@ -44,6 +39,5 @@ public: std::function<void(QImage)> callback); private: - static QSharedPointer<MatrixClient> client_; static QSharedPointer<Cache> cache_; };