mirror of
https://github.com/vector-im/element-ios.git
synced 2024-09-29 15:52:40 +00:00
BubbleRoomTimelineCellProvider: Handle poll cells.
This commit is contained in:
parent
ac1b9e9b86
commit
66103719fd
1 changed files with 25 additions and 0 deletions
|
@ -75,6 +75,17 @@
|
|||
[tableView registerClass:VoiceMessageOutgoingWithPaginationTitleBubbleCell.class forCellReuseIdentifier:VoiceMessageOutgoingWithPaginationTitleBubbleCell.defaultReuseIdentifier];
|
||||
}
|
||||
|
||||
- (void)registerPollCellsForTableView:(UITableView *)tableView
|
||||
{
|
||||
// Incoming
|
||||
[tableView registerClass:PollIncomingBubbleCell.class forCellReuseIdentifier:PollIncomingBubbleCell.defaultReuseIdentifier];
|
||||
[tableView registerClass:PollIncomingWithoutSenderInfoBubbleCell.class forCellReuseIdentifier:PollIncomingWithoutSenderInfoBubbleCell.defaultReuseIdentifier];
|
||||
[tableView registerClass:PollIncomingWithPaginationTitleBubbleCell.class forCellReuseIdentifier:PollIncomingWithPaginationTitleBubbleCell.defaultReuseIdentifier];
|
||||
// Outgoing
|
||||
[tableView registerClass:PollOutgoingWithoutSenderInfoBubbleCell.class forCellReuseIdentifier:PollOutgoingWithoutSenderInfoBubbleCell.defaultReuseIdentifier];
|
||||
[tableView registerClass:PollOutgoingWithPaginationTitleBubbleCell.class forCellReuseIdentifier:PollOutgoingWithPaginationTitleBubbleCell.defaultReuseIdentifier];
|
||||
}
|
||||
|
||||
- (void)registerLocationCellsForTableView:(UITableView*)tableView
|
||||
{
|
||||
// Incoming
|
||||
|
@ -177,6 +188,20 @@
|
|||
};
|
||||
}
|
||||
|
||||
- (NSDictionary<NSNumber *,Class> *)pollCellsMapping
|
||||
{
|
||||
return @{
|
||||
// Incoming
|
||||
@(RoomTimelineCellIdentifierIncomingPoll) : PollIncomingBubbleCell.class,
|
||||
@(RoomTimelineCellIdentifierIncomingPollWithoutSenderInfo) : PollIncomingWithoutSenderInfoBubbleCell.class,
|
||||
@(RoomTimelineCellIdentifierIncomingPollWithPaginationTitle) : PollIncomingWithPaginationTitleBubbleCell.class,
|
||||
// Outgoing
|
||||
@(RoomTimelineCellIdentifierOutgoingPoll) : PollOutgoingWithoutSenderInfoBubbleCell.class,
|
||||
@(RoomTimelineCellIdentifierOutgoingPollWithoutSenderInfo) : PollOutgoingWithoutSenderInfoBubbleCell.class,
|
||||
@(RoomTimelineCellIdentifierOutgoingPollWithPaginationTitle) : PollOutgoingWithPaginationTitleBubbleCell.class,
|
||||
};
|
||||
}
|
||||
|
||||
- (NSDictionary<NSNumber*, Class>*)locationCellsMapping
|
||||
{
|
||||
return @{
|
||||
|
|
Loading…
Reference in a new issue