Update libqmatrixclient && fix file posting caused by upstream change.
This commit is contained in:
parent
d60bd1ed9f
commit
a105f344f4
|
@ -1 +1 @@
|
|||
Subproject commit cbb8c1bf4e33639d8a00341021542de99bd6bce2
|
||||
Subproject commit 941cfdf8b591bf14002f28e99e06c200dc5bcc84
|
|
@ -84,11 +84,11 @@ void Controller::postFile(QMatrixClient::Room* room, const QUrl& localFile,
|
|||
if (mime.startsWith("image")) msgType = "m.image";
|
||||
if (mime.startsWith("video")) msgType = "m.video";
|
||||
if (mime.startsWith("audio")) msgType = "m.audio";
|
||||
QJsonObject json{{"content", QJsonObject{{"msgtype", msgType},
|
||||
{"body", fileName},
|
||||
{"filename", fileName},
|
||||
{"url", mxcUrl.url()}}}};
|
||||
room->postMessage(QMatrixClient::RoomMessageEvent(json));
|
||||
QJsonObject json{QJsonObject{{"msgtype", msgType},
|
||||
{"body", fileName},
|
||||
{"filename", fileName},
|
||||
{"url", mxcUrl.url()}}};
|
||||
room->postMessage("m.room.message", json);
|
||||
}
|
||||
|
||||
QString Controller::getMIME(const QUrl& fileUrl) const {
|
||||
|
|
Loading…
Reference in New Issue