使用 UITapGestureRecognizer ,创建一个 UITapGestureRecognizer 将它添加到view上即可
UIView *tapView=[[UIView alloc]initWithFrame:SCREEN_FRAME];
UITapGestureRecognizer *tapGesturRecognizer=[[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(tapAction:)];
[tapView addGestureRecognizer:tapGesturRecognizer];
-(void)tapAction:(id)tap {
NSLog(@"点击了tapView");
}