diff options
author | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2019-02-12 22:11:23 +0900 |
---|---|---|
committer | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2019-02-15 07:49:56 +0900 |
commit | e12fc32b94c3840249676b2e0656c174846f1c6e (patch) | |
tree | 1ac38da44940068b5b30927d6ee2d437fb12e8b3 /lib/connection.h | |
parent | 9a0f5ce3de03cb7479737da62b38fd6a63898651 (diff) | |
download | libquotient-e12fc32b94c3840249676b2e0656c174846f1c6e.tar.gz libquotient-e12fc32b94c3840249676b2e0656c174846f1c6e.zip |
Connection: load supported room versions
A part of #236.
Diffstat (limited to 'lib/connection.h')
-rw-r--r-- | lib/connection.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/connection.h b/lib/connection.h index 8c938df2..e5bce52e 100644 --- a/lib/connection.h +++ b/lib/connection.h @@ -102,6 +102,7 @@ namespace QMatrixClient Q_PROPERTY(QString localUserId READ userId NOTIFY stateChanged) Q_PROPERTY(QString deviceId READ deviceId NOTIFY stateChanged) Q_PROPERTY(QByteArray accessToken READ accessToken NOTIFY stateChanged) + Q_PROPERTY(QString defaultRoomVersion READ defaultRoomVersion NOTIFY capabilitiesLoaded) Q_PROPERTY(QUrl homeserver READ homeserver WRITE setHomeserver NOTIFY homeserverChanged) Q_PROPERTY(bool cacheState READ cacheState WRITE setCacheState NOTIFY cacheStateChanged) Q_PROPERTY(bool lazyLoading READ lazyLoading WRITE setLazyLoading NOTIFY lazyLoadingChanged) @@ -257,6 +258,10 @@ namespace QMatrixClient Q_INVOKABLE QString token() const; Q_INVOKABLE void getTurnServers(); + QString defaultRoomVersion() const; + QStringList stableRoomVersions() const; + const QHash<QString, QString>& availableRoomVersions() const; + /** * Call this before first sync to load from previously saved file. * @@ -365,6 +370,8 @@ namespace QMatrixClient const QString& deviceId = {}); void connectWithToken(const QString& userId, const QString& accessToken, const QString& deviceId); + /** Explicitly request capabilities from the server */ + void reloadCapabilities(); /** @deprecated Use stopSync() instead */ void disconnectFromServer() { stopSync(); } @@ -501,6 +508,7 @@ namespace QMatrixClient void resolveError(QString error); void homeserverChanged(QUrl baseUrl); + void capabilitiesLoaded(); void connected(); void reconnected(); //< \deprecated Use connected() instead |