IOS部分CODE

 [self.view removeFromSuperview];

gestureRecognizer自动检测是否通过

-(BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldReceiveTouch:(UITouch *)touch{

    CGPoint touchLocation = [touch locationInView:self.view];

            NSLog(@"Tapped image view");

    return !CGRectContainsPoint(self.judgeRemoveThisVew.frame, touchLocation);

    }



@property (retain, nonatomic) IBOutlet UIView *judgeRemoveThisVew;



你可能感兴趣的:(IOS部分CODE)