diff options
author | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2018-01-26 09:00:33 +0900 |
---|---|---|
committer | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2018-01-26 09:00:33 +0900 |
commit | 76bff84a2aa63db677044cc529b910768fa018fa (patch) | |
tree | efeb34e37b436267313169a1790e45a07e8f7fcb /user.h | |
parent | 7d506f7bebbcc3b5f8a37589f8fda6fa1e7e1efd (diff) | |
parent | 2f83e4be20a15013181c1ba6944e21f051ccac9d (diff) | |
download | libquotient-76bff84a2aa63db677044cc529b910768fa018fa.tar.gz libquotient-76bff84a2aa63db677044cc529b910768fa018fa.zip |
Merge branch 'master' into kitsune-gtad
Diffstat (limited to 'user.h')
-rw-r--r-- | user.h | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -33,6 +33,8 @@ namespace QMatrixClient Q_PROPERTY(QString name READ name NOTIFY nameChanged) Q_PROPERTY(QString displayName READ displayname NOTIFY nameChanged STORED false) Q_PROPERTY(QString bridgeName READ bridged NOTIFY nameChanged STORED false) + Q_PROPERTY(QString avatarMediaId READ avatarMediaId NOTIFY avatarChanged STORED false) + Q_PROPERTY(QUrl avatarUrl READ avatarUrl NOTIFY avatarChanged) public: User(QString userId, Connection* connection); ~User() override; @@ -57,11 +59,12 @@ namespace QMatrixClient */ QString bridged() const; - const Avatar& avatarObject(); + const Avatar& avatarObject() const; Q_INVOKABLE QImage avatar(int dimension); Q_INVOKABLE QImage avatar(int requestedWidth, int requestedHeight); - Q_INVOKABLE QUrl avatarUrl() const; + QString avatarMediaId() const; + QUrl avatarUrl() const; void processEvent(Event* event); @@ -83,3 +86,4 @@ namespace QMatrixClient Private* d; }; } +Q_DECLARE_METATYPE(QMatrixClient::User*) |