Removed the ReceiptsContainerDelegate, used didRecognizeAction: instead

This commit is contained in:
Aram Sargsyan
2017-06-26 19:33:53 +04:00
parent e0d393350b
commit 1f48a6d946
4 changed files with 19 additions and 10 deletions
+5 -2
View File
@@ -191,7 +191,6 @@
{
// Define the read receipts container, positioned on the right border of the bubble cell (Note the right margin 6 pts).
MXKReceiptSendersContainer* avatarsContainer = [[MXKReceiptSendersContainer alloc] initWithFrame:CGRectMake(bubbleCell.frame.size.width - 156, bottomPositionY - 13, 150, 12) andRestClient:self.mxSession.matrixRestClient];
avatarsContainer.delegate = [AppDelegate theDelegate].masterTabBarController.currentRoomViewController;
// Custom avatar display
avatarsContainer.maxDisplayedAvatars = 5;
@@ -201,8 +200,12 @@
avatarsContainer.tag = index;
[avatarsContainer refreshReceiptSenders:roomMembers withPlaceHolders:placeholders andAlignment:ReadReceiptAlignmentRight];
avatarsContainer.mxSession = self.mxSession;
avatarsContainer.readReceipts = receipts;
UITapGestureRecognizer *tapRecognizer = [[UITapGestureRecognizer alloc] initWithTarget:cell action:@selector(onReceiptContainerTap:)];
[tapRecognizer setNumberOfTapsRequired:1];
[tapRecognizer setNumberOfTouchesRequired:1];
[avatarsContainer addGestureRecognizer:tapRecognizer];
avatarsContainer.userInteractionEnabled = YES;
avatarsContainer.translatesAutoresizingMaskIntoConstraints = NO;
avatarsContainer.accessibilityIdentifier = @"readReceiptsContainer";