I have found what causes this problem. It was my UserGoldsViewCell
that overrides hitTest:withEvent
method. Below was my old implementation of the method:
- (UIView *)hitTest:(CGPoint) point withEvent:(UIEvent *)event {
if ([self pointInside:point withEvent:event]) {
return scrollView;
}
return nil;
}
I override this method because my UserGoldsViewCell
has a UISrollView
in it and for a reason, I need to override it. The reason why my UserSilverCell
does not respond to touch event after selecting UserGoldsViewCell
is because even the presented cells are UserSilverCell
instance, the hitTest:withEvent
in my UserGoldsViewCell
still gets called and returning its' scrollView. I change my implementation for this method like below:
-(UIView*)hitTest:(CGPoint)point withEvent:(UIEvent*)event
{
UIView* childObj = nil;
if ((childObj = [super hitTest:point withEvent:event]) == self)
return self.scrollView;
return childObj;
}