diff options
author | George Hazan <ghazan@miranda.im> | 2019-12-18 20:39:59 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2019-12-18 20:39:59 +0300 |
commit | fe77d2543f2822b6637c4090887bf349fc4ccb75 (patch) | |
tree | c3ab1b2e4e9a1c4ca3bf1ee8a5b9a316e77ab83b /protocols/Facebook/src/proto.h | |
parent | 406f0e4a4f42979778757243ed29c2753cbb1107 (diff) |
Facebook:
- MqttSend now calculates payload size automatically (no need to add some magic numbers);
- support for MQTT publish requests;
- minor code cleaning
Diffstat (limited to 'protocols/Facebook/src/proto.h')
-rw-r--r-- | protocols/Facebook/src/proto.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/protocols/Facebook/src/proto.h b/protocols/Facebook/src/proto.h index 761b49edb2..f64eb5c3ea 100644 --- a/protocols/Facebook/src/proto.h +++ b/protocols/Facebook/src/proto.h @@ -339,13 +339,17 @@ public: class FacebookProto : public PROTO<FacebookProto> { + uint8_t* doZip(size_t cbData, const void *pData, size_t &cbRes); + AsyncHttpRequest *CreateRequest(const char *szName, const char *szMethod); AsyncHttpRequest *CreateRequestGQL(int64_t id); NETLIBHTTPREQUEST *ExecuteRequest(AsyncHttpRequest *pReq); // MQTT functions bool MqttConnect(); - void MqttOpen(); + void MqttOpen(); + void MqttPublish(const char *topic, const char *value); + void MqttSend(const MqttMessage &payload); HNETLIBCONN m_mqttConn; @@ -354,6 +358,7 @@ class FacebookProto : public PROTO<FacebookProto> CMStringA m_szClientID; // stored, random alphanumeric string of 20 chars __int64 m_uid; // stored, Facebook user id __int64 m_iMqttId; + int16_t m_mid; bool m_invisible; bool m_bOnline; |