I have subclassed UICollectionView
as CoolGridCollectionView
and I have overrides the touchesBegan:
and touchesEnded:
methods. But those are not getting called, when I tap the cell. And that cells are having single and double tap gesture recognisers. I need the position, where the tap has happened. I can get the position by using covertPoint:
something else. But Why the touches methods are not called? Does iOS handles touches of UICollectionView
specifically.
Asked
Active
Viewed 758 times
1

Shanmugaraja G
- 2,778
- 4
- 31
- 47
-
add Gesture in windows, you get Touch – Ujesh Jul 04 '16 at 11:04
1 Answers
0
I’m not 100% sure, but you can try hitTest:withEvent: method instead of -touchesBegan:withEvent: method. Hope this will helpful to you.
- (UIView *)hitTest:(CGPoint)point withEvent:(UIEvent *)event {
touchedView = [super hitTest:point withEvent:event];
NSSet* touches = [event allTouches];
// handle touches if you need
return touchedView;
}

TestGrid.io Team
- 1
- 5