Merge branch 'develop' into ismail/5096_thread_notifications

This commit is contained in:
ismailgulek
2022-02-02 12:46:00 +03:00
108 changed files with 1709 additions and 611 deletions
+81 -15
View File
@@ -2012,7 +2012,7 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
[self.delegate roomViewControllerDidRequestPollCreationFormPresentation:self];
}]];
}
if (RiotSettings.shared.roomScreenAllowLocationAction)
if (BuildSettings.locationSharingEnabled)
{
[actionItems addObject:[[RoomActionItem alloc] initWithImage:[UIImage imageNamed:@"action_location"] andAction:^{
MXStrongifyAndReturnIfNil(self);
@@ -2704,17 +2704,35 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
}
else if (bubbleData.attachment.type == MXKAttachmentTypeVoiceMessage || bubbleData.attachment.type == MXKAttachmentTypeAudio)
{
if (bubbleData.isPaginationFirstBubble)
if (bubbleData.isIncoming)
{
cellIdentifier = RoomTimelineCellIdentifierVoiceMessageWithPaginationTitle;
}
else if (bubbleData.shouldHideSenderInformation)
{
cellIdentifier = RoomTimelineCellIdentifierVoiceMessageWithoutSenderInfo;
if (bubbleData.isPaginationFirstBubble)
{
cellIdentifier = RoomTimelineCellIdentifierIncomingVoiceMessageWithPaginationTitle;
}
else if (bubbleData.shouldHideSenderInformation)
{
cellIdentifier = RoomTimelineCellIdentifierIncomingVoiceMessageWithoutSenderInfo;
}
else
{
cellIdentifier = RoomTimelineCellIdentifierIncomingVoiceMessage;
}
}
else
{
cellIdentifier = RoomTimelineCellIdentifierVoiceMessage;
if (bubbleData.isPaginationFirstBubble)
{
cellIdentifier = RoomTimelineCellIdentifierOutgoingVoiceMessageWithPaginationTitle;
}
else if (bubbleData.shouldHideSenderInformation)
{
cellIdentifier = RoomTimelineCellIdentifierOutgoingVoiceMessageWithoutSenderInfo;
}
else
{
cellIdentifier = RoomTimelineCellIdentifierOutgoingVoiceMessage;
}
}
}
else if (bubbleData.tag == RoomBubbleCellDataTagPoll)
@@ -2734,17 +2752,35 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
}
else if (bubbleData.tag == RoomBubbleCellDataTagLocation)
{
if (bubbleData.isPaginationFirstBubble)
if (bubbleData.isIncoming)
{
cellIdentifier = RoomTimelineCellIdentifierLocationWithPaginationTitle;
}
else if (bubbleData.shouldHideSenderInformation)
{
cellIdentifier = RoomTimelineCellIdentifierLocationWithoutSenderInfo;
if (bubbleData.isPaginationFirstBubble)
{
cellIdentifier = RoomTimelineCellIdentifierIncomingLocationWithPaginationTitle;
}
else if (bubbleData.shouldHideSenderInformation)
{
cellIdentifier = RoomTimelineCellIdentifierIncomingLocationWithoutSenderInfo;
}
else
{
cellIdentifier = RoomTimelineCellIdentifierIncomingLocation;
}
}
else
{
cellIdentifier = RoomTimelineCellIdentifierLocation;
if (bubbleData.isPaginationFirstBubble)
{
cellIdentifier = RoomTimelineCellIdentifierOutgoingLocationWithPaginationTitle;
}
else if (bubbleData.shouldHideSenderInformation)
{
cellIdentifier = RoomTimelineCellIdentifierOutgoingLocationWithoutSenderInfo;
}
else
{
cellIdentifier = RoomTimelineCellIdentifierOutgoingLocation;
}
}
}
else if (bubbleData.isIncoming)
@@ -2769,6 +2805,21 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
cellIdentifier = showEncryptionBadge ? RoomTimelineCellIdentifierIncomingAttachmentEncrypted : RoomTimelineCellIdentifierIncomingAttachment;
}
}
else if (bubbleData.isAttachment)
{
if (bubbleData.isPaginationFirstBubble)
{
cellIdentifier = showEncryptionBadge ? RoomTimelineCellIdentifierIncomingAttachmentWithoutThumbnailEncryptedWithPaginationTitle : RoomTimelineCellIdentifierIncomingAttachmentWithoutThumbnailWithPaginationTitle;
}
else if (bubbleData.shouldHideSenderInformation)
{
cellIdentifier = showEncryptionBadge ? RoomTimelineCellIdentifierIncomingAttachmentWithoutThumbnailEncryptedWithoutSenderInfo : RoomTimelineCellIdentifierIncomingAttachmentWithoutThumbnailWithoutSenderInfo;
}
else
{
cellIdentifier = showEncryptionBadge ? RoomTimelineCellIdentifierIncomingAttachmentWithoutThumbnailEncrypted : RoomTimelineCellIdentifierIncomingAttachmentWithoutThumbnail;
}
}
else
{
if (bubbleData.isPaginationFirstBubble)
@@ -2819,6 +2870,21 @@ const NSTimeInterval kResizeComposerAnimationDuration = .05;
cellIdentifier = showEncryptionBadge ? RoomTimelineCellIdentifierOutgoingAttachmentEncrypted : RoomTimelineCellIdentifierOutgoingAttachment;
}
}
else if (bubbleData.isAttachment)
{
if (bubbleData.isPaginationFirstBubble)
{
cellIdentifier = showEncryptionBadge ? RoomTimelineCellIdentifierOutgoingAttachmentWithoutThumbnailEncryptedWithPaginationTitle : RoomTimelineCellIdentifierOutgoingAttachmentWithoutThumbnailWithPaginationTitle;
}
else if (bubbleData.shouldHideSenderInformation)
{
cellIdentifier = showEncryptionBadge ? RoomTimelineCellIdentifierOutgoingAttachmentWithoutThumbnailEncryptedWithoutSenderInfo : RoomTimelineCellIdentifierOutgoingAttachmentWithoutThumbnailWithoutSenderInfo;
}
else
{
cellIdentifier = showEncryptionBadge ? RoomTimelineCellIdentifierOutgoingAttachmentWithoutThumbnailEncrypted : RoomTimelineCellIdentifierOutgoingAttachmentWithoutThumbnail;
}
}
else
{
if (bubbleData.isPaginationFirstBubble)