aboutsummaryrefslogtreecommitdiff
path: root/lib/room.h
diff options
context:
space:
mode:
authorKitsune Ral <Kitsune-Ral@users.sf.net>2019-05-18 13:52:54 +0900
committerKitsune Ral <Kitsune-Ral@users.sf.net>2019-07-31 11:28:11 +0900
commitb89d5c43746ed672d98bf350db2a9e1b0878e2d0 (patch)
treedb165438b8ca34d2a211385f2d9d446eaf9e8537 /lib/room.h
parentb87097866f38b90f36fb216b7516a135227930a1 (diff)
downloadlibquotient-b89d5c43746ed672d98bf350db2a9e1b0878e2d0.tar.gz
libquotient-b89d5c43746ed672d98bf350db2a9e1b0878e2d0.zip
Support for receiving m.reaction events
* struct EventRelation; class ReactionEvent; Room::relatedEvents() * Reaction events are processed in both history and sync batches * Redacting a reaction removes it from the list of related events * QMCTest::sendReaction()
Diffstat (limited to 'lib/room.h')
-rw-r--r--lib/room.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/room.h b/lib/room.h
index c79ca1e0..65b9070a 100644
--- a/lib/room.h
+++ b/lib/room.h
@@ -121,6 +121,7 @@ namespace QMatrixClient
public:
using Timeline = std::deque<TimelineItem>;
using PendingEvents = std::vector<PendingEventItem>;
+ using RelatedEvents = QVector<const RoomEvent*>;
using rev_iter_t = Timeline::const_reverse_iterator;
using timeline_iter_t = Timeline::const_iterator;
@@ -264,6 +265,11 @@ namespace QMatrixClient
PendingEvents::iterator findPendingEvent(const QString & txnId);
PendingEvents::const_iterator findPendingEvent(const QString & txnId) const;
+ const RelatedEvents relatedEvents(const QString& evtId,
+ const char* relType) const;
+ const RelatedEvents relatedEvents(const RoomEvent& evt,
+ const char* relType) const;
+
bool displayed() const;
/// Mark the room as currently displayed to the user
/**
@@ -584,6 +590,7 @@ namespace QMatrixClient
void tagsAboutToChange();
void tagsChanged();
+ void updatedEvent(QString eventId);
void replacedEvent(const RoomEvent* newEvent,
const RoomEvent* oldEvent);