iphone点击空白隐藏键盘
-(void) touchesBegan:(NSSet*)touches withEvent:(UIEvent*)event{
UITouch*touch =[touches anyObject];
if(touch.phase==UITouchPhaseBegan){
//find first response view
for(UIView*view in[self.view subviews]){
if([view isFirstResponder]){
[view resignFirstResponder];
break;
}
}
}
}