try it -
In your cellForRowAtIndexPath method cellForRowAtIndexPath you can add a gesture gesture and a hard print gesture separately, and then implement them. However, your didselect function didselect not required, and you do not need deSelect anything.
UITapGestureRecognizer *tapGestureRecognizer = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(cellTapped:)]; tapGestureRecognizer.numberOfTapsRequired = 1; tapGestureRecognizer.numberOfTouchesRequired = 1; cell.tag = indexPath.row; [cell addGestureRecognizer:tapGestureRecognizer]; UILongPressGestureRecognizer *lpgr = [[UILongPressGestureRecognizer alloc] initWithTarget:self action:@selector(handleLongPress:)]; lpgr.minimumPressDuration = 1.0;
Now
-(void)handleLongPress:(UILongPressGestureRecognizer *)longPress {
source share