From 69ff191c83e5277cfe22d3735e9ac2f0256be3c5 Mon Sep 17 00:00:00 2001 From: link2xt Date: Sat, 29 May 2021 23:40:34 +0300 Subject: Implement message drafts --- context.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'context.h') diff --git a/context.h b/context.h index df3fbfb..2d31f71 100644 --- a/context.h +++ b/context.h @@ -39,6 +39,8 @@ public: Q_INVOKABLE DcMessage *getMessage(uint32_t msgId); Q_INVOKABLE DcContact *getContact(uint32_t contactId); Q_INVOKABLE uint32_t sendTextMessage(uint32_t chatId, QString textToSend); + Q_INVOKABLE void setDraft(uint32_t chatId, DcMessage *message); + Q_INVOKABLE DcMessage *getDraft(uint32_t chatId); QString getBlobdir(); Q_INVOKABLE bool setConfig(QString key, QString value); Q_INVOKABLE QString getConfig(QString key); @@ -46,6 +48,7 @@ public: Q_INVOKABLE QString getMessageInfo(uint32_t msgId); Q_INVOKABLE QString getMessageHtml(uint32_t msgId); Q_INVOKABLE uint32_t decideOnContactRequest(uint32_t msgId, int decision); + Q_INVOKABLE DcMessage *newMessage(int viewtype); private: dc_context_t *m_context{nullptr}; -- cgit v1.2.3-70-g09d2