diff options
author | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2019-01-03 17:57:42 +0900 |
---|---|---|
committer | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2019-01-05 21:01:34 +0900 |
commit | 816377ea3c204f22698e1458b815fdd3c3837adc (patch) | |
tree | 092a711c6504c9e1945e5e1b566ee362123f57ef | |
parent | e3c1b93483eafbb94f1224b57e562984f4100538 (diff) | |
download | libquotient-816377ea3c204f22698e1458b815fdd3c3837adc.tar.gz libquotient-816377ea3c204f22698e1458b815fdd3c3837adc.zip |
More defaults to construct LocationContent and PlayableContent
-rw-r--r-- | lib/events/roommessageevent.cpp | 3 | ||||
-rw-r--r-- | lib/events/roommessageevent.h | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/lib/events/roommessageevent.cpp b/lib/events/roommessageevent.cpp index 572c7173..69969c0f 100644 --- a/lib/events/roommessageevent.cpp +++ b/lib/events/roommessageevent.cpp @@ -200,7 +200,8 @@ void TextContent::fillJson(QJsonObject* json) const } } -LocationContent::LocationContent(const QString& geoUri, const ImageInfo& thumbnail) +LocationContent::LocationContent(const QString& geoUri, + const Thumbnail& thumbnail) : geoUri(geoUri), thumbnail(thumbnail) { } diff --git a/lib/events/roommessageevent.h b/lib/events/roommessageevent.h index a4ba6e65..5657135b 100644 --- a/lib/events/roommessageevent.h +++ b/lib/events/roommessageevent.h @@ -122,7 +122,7 @@ namespace QMatrixClient { public: LocationContent(const QString& geoUri, - const ImageInfo& thumbnail); + const Thumbnail& thumbnail = {}); explicit LocationContent(const QJsonObject& json); QMimeType type() const override; @@ -142,6 +142,7 @@ namespace QMatrixClient class PlayableContent : public ContentT { public: + using ContentT::ContentT; PlayableContent(const QJsonObject& json) : ContentT(json) , duration(ContentT::originalInfoJson["duration"_ls].toInt()) |