29,048
社区成员




UITouch * touch = touches.anyObject;
CGPoint location2 = [touch locationInView:self];
-(void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event{
// UIWindow * window1 = (UIWindow *)self.view.superview;
// NSLog(@"%@",window1);
AppDelegate * app = (AppDelegate *)[UIApplication sharedApplication].delegate;
UIWindow * window2 = app.window;
NSLog(@"%@",window2);
UITouch * touch = touches.anyObject;
CGPoint location2 = [touch locationInView:window2];
NSLog(@"%@",NSStringFromCGPoint(location2));
}
就是状态栏点击没有效果。