diff options
Diffstat (limited to 'events')
-rw-r--r-- | events/event.h | 8 | ||||
-rw-r--r-- | events/roommessageevent.cpp | 2 | ||||
-rw-r--r-- | events/roommessageevent.h | 4 |
3 files changed, 7 insertions, 7 deletions
diff --git a/events/event.h b/events/event.h index a009aa99..72d26208 100644 --- a/events/event.h +++ b/events/event.h @@ -65,12 +65,12 @@ namespace QMatrixClient * @return an iterator to an item with the earliest timestamp after * the one of 'item'; or timeline.end(), if all events are earlier */ - template <class ItemT, template <typename> class ContT> - typename ContT<ItemT *>::iterator - findInsertionPos(ContT<ItemT *> & timeline, const ItemT *item) + template <class ItemT, class ContT> + typename ContT::iterator + findInsertionPos(ContT & timeline, const ItemT *item) { return std::lower_bound (timeline.begin(), timeline.end(), item, - [](const ItemT * a, const ItemT * b) { + [](const typename ContT::value_type a, const ItemT * b) { return a->timestamp() < b->timestamp(); } ); diff --git a/events/roommessageevent.cpp b/events/roommessageevent.cpp index b7459054..48f52453 100644 --- a/events/roommessageevent.cpp +++ b/events/roommessageevent.cpp @@ -171,7 +171,7 @@ RoomMessageEvent* RoomMessageEvent::fromJson(const QJsonObject& obj) { qDebug() << "RoomMessageEvent: unknown msgtype: " << msgtype; qDebug() << obj; - e->d->msgtype = MessageEventType::Unkown; + e->d->msgtype = MessageEventType::Unknown; e->d->content = new MessageEventContent; } diff --git a/events/roommessageevent.h b/events/roommessageevent.h index 939113d1..b0d5a1cb 100644 --- a/events/roommessageevent.h +++ b/events/roommessageevent.h @@ -27,7 +27,7 @@ namespace QMatrixClient { enum class MessageEventType { - Text, Emote, Notice, Image, File, Location, Video, Audio, Unkown + Text, Emote, Notice, Image, File, Location, Video, Audio, Unknown }; class MessageEventContent @@ -115,4 +115,4 @@ namespace QMatrixClient } -#endif // QMATRIXCLIENT_ROOMMESSAGEEVENT_H
\ No newline at end of file +#endif // QMATRIXCLIENT_ROOMMESSAGEEVENT_H |