Replace shared pointers of MatrixClient with a single instance

This commit is contained in:
Konstantinos Sideris 2018-05-08 18:43:56 +03:00
parent ffb43836e4
commit 4c4ea557b3
31 changed files with 196 additions and 269 deletions

View file

@ -43,7 +43,7 @@ class MatrixClient : public QNetworkAccessManager
{
Q_OBJECT
public:
MatrixClient(QString server, QObject *parent = 0);
MatrixClient(QObject *parent = 0);
// Client API.
void initialSync() noexcept;
@ -211,3 +211,13 @@ private:
//! Filter to be send as filter-param for (initial) /sync requests.
QString filter_;
};
namespace http {
//! Initialize the http module
void
init(QObject *parent);
//! Retrieve the client instance.
MatrixClient *
client();
}