Add new action for the thread root event in thread view

This commit is contained in:
ismailgulek
2021-11-12 17:25:58 +03:00
parent 93f2fb024f
commit fbb78b402e
3 changed files with 19 additions and 0 deletions
+14
View File
@@ -3259,6 +3259,20 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
}]];
}
if (self.roomDataSource.threadId && [selectedEvent.eventId isEqualToString:self.roomDataSource.threadId])
{
// if in the thread and selected event is the root event
// add "View in room" action
[currentAlert addAction:[UIAlertAction actionWithTitle:[VectorL10n roomEventActionViewInRoom]
style:UIAlertActionStyleDefault
handler:^(UIAlertAction * action) {
MXStrongifyAndReturnIfNil(self);
[self.delegate roomViewController:self
showRoomWithId:self.roomDataSource.roomId
eventId:selectedEvent.eventId];
}]];
}
if (!isJitsiCallEvent)
{
[currentAlert addAction:[UIAlertAction actionWithTitle:[VectorL10n roomEventActionQuote]