summary refs log tree commit diff
path: root/src/timeline/TimelineModel.cpp
diff options
context:
space:
mode:
authorNicolas Werner <nicolas.werner@hotmail.de>2023-07-28 20:05:47 +0200
committerNicolas Werner <nicolas.werner@hotmail.de>2023-08-25 19:03:15 +0200
commit718a58d388abd228c6a08f9fa3365588c06923ba (patch)
treedab9877a7bd16fd291fcd16262d868cf87469c67 /src/timeline/TimelineModel.cpp
parentPort redacted messages (diff)
downloadnheko-718a58d388abd228c6a08f9fa3365588c06923ba.tar.xz
Get rid of redundant constructions and make room implicit
Diffstat (limited to 'src/timeline/TimelineModel.cpp')
-rw-r--r--src/timeline/TimelineModel.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/timeline/TimelineModel.cpp b/src/timeline/TimelineModel.cpp

index 066d8b01..66f7d5b8 100644 --- a/src/timeline/TimelineModel.cpp +++ b/src/timeline/TimelineModel.cpp
@@ -561,6 +561,7 @@ TimelineModel::roleNames() const {ReplyTo, "replyTo"}, {ThreadId, "threadId"}, {Reactions, "reactions"}, + {Room, "room"}, {RoomId, "roomId"}, {RoomName, "roomName"}, {RoomTopic, "roomTopic"}, @@ -899,6 +900,8 @@ TimelineModel::data(const mtx::events::collections::TimelineEvents &event, int r auto id = relations(event).replaces().value_or(event_id(event)); return QVariant::fromValue(events.reactions(id)); } + case Room: + return QVariant::fromValue(this); case RoomId: return QVariant(room_id_); case RoomName: