From 1e48c18f6a7c6cd3c751e3156310a53bc63c27fc Mon Sep 17 00:00:00 2001 From: Kitsune Ral Date: Sat, 3 Feb 2018 19:20:53 +0900 Subject: thumbnailInfo() for event content classes and RoomMessageEvent: hasThumbnail --- events/roommessageevent.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'events/roommessageevent.cpp') diff --git a/events/roommessageevent.cpp b/events/roommessageevent.cpp index 8c088f21..dec0ca50 100644 --- a/events/roommessageevent.cpp +++ b/events/roommessageevent.cpp @@ -128,6 +128,11 @@ bool RoomMessageEvent::hasFileContent() const return content() && content()->fileInfo(); } +bool RoomMessageEvent::hasThumbnail() const +{ + return content() && content()->thumbnailInfo(); +} + QJsonObject RoomMessageEvent::toJson() const { QJsonObject obj = _content ? _content->toJson() : QJsonObject(); -- cgit v1.2.3