PlainRoomTimelineCellProvider: Handle new voice message cell identifiers.

This commit is contained in:
SBiOSoftWhare
2022-01-25 14:53:05 +01:00
parent dca38b5c70
commit e3e5f9d1ff
2 changed files with 16 additions and 3 deletions
@@ -20,10 +20,18 @@ NS_ASSUME_NONNULL_BEGIN
@interface PlainRoomTimelineCellProvider: NSObject<RoomTimelineCellProvider>
#pragma mark - Registration
- (void)registerVoiceMessageCellsForTableView:(UITableView*)tableView;
#pragma mark - Mapping
- (NSDictionary<NSNumber*, Class>*)outgoingTextMessageCellsMapping;
- (NSDictionary<NSNumber*, Class>*)outgoingAttachmentCellsMapping;
- (NSDictionary<NSNumber*, Class>*)voiceMessageCellsMapping;
@end
NS_ASSUME_NONNULL_END
@@ -425,9 +425,14 @@
- (NSDictionary<NSNumber*, Class>*)voiceMessageCellsMapping
{
return @{
@(RoomTimelineCellIdentifierVoiceMessage) : VoiceMessageBubbleCell.class,
@(RoomTimelineCellIdentifierVoiceMessageWithoutSenderInfo) : VoiceMessageWithoutSenderInfoBubbleCell.class,
@(RoomTimelineCellIdentifierVoiceMessageWithPaginationTitle) : VoiceMessageWithPaginationTitleBubbleCell.class,
// Incoming
@(RoomTimelineCellIdentifierIncomingVoiceMessage) : VoiceMessageBubbleCell.class,
@(RoomTimelineCellIdentifierIncomingVoiceMessageWithoutSenderInfo) : VoiceMessageWithoutSenderInfoBubbleCell.class,
@(RoomTimelineCellIdentifierIncomingVoiceMessageWithPaginationTitle) : VoiceMessageWithPaginationTitleBubbleCell.class,
// Outoing
@(RoomTimelineCellIdentifierOutgoingVoiceMessage) : VoiceMessageBubbleCell.class,
@(RoomTimelineCellIdentifierOutgoingVoiceMessageWithoutSenderInfo) : VoiceMessageWithoutSenderInfoBubbleCell.class,
@(RoomTimelineCellIdentifierOutgoingVoiceMessageWithPaginationTitle) : VoiceMessageWithPaginationTitleBubbleCell.class
};
}