hitTest
2020-11-20 本文已影响0人
开发者老岳
按需求屏蔽事件,默认是返回[super hitTest:point withEvent:event],若想某个区域无事件,则返回 nil。
- (UIView *)hitTest:(CGPoint)point withEvent:(UIEvent *)event
{
if (xxx) {
return nil;
}
return [super hitTest:point withEvent:event];
}