Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/objective-c/27.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ios 如何在objective-c中访问UITAPPostation中的子视图控件?_Ios_Objective C_Iphone - Fatal编程技术网

Ios 如何在objective-c中访问UITAPPostation中的子视图控件?

Ios 如何在objective-c中访问UITAPPostation中的子视图控件?,ios,objective-c,iphone,Ios,Objective C,Iphone,朋友们好,请帮帮我, 我已经在UIWindow上添加了UIAPT手势,但我无法访问屏幕中的父控件 UIRotationGestureRecognizer *rot =[[UIRotationGestureRecognizer alloc] initWithTarget:self action:@selector(handleRotation:)]; rot.cancelsTouchesInView = NO; rot.delegate = self; UIPinchGestureRecog

朋友们好,请帮帮我, 我已经在UIWindow上添加了UIAPT手势,但我无法访问屏幕中的父控件

UIRotationGestureRecognizer *rot =[[UIRotationGestureRecognizer alloc] initWithTarget:self action:@selector(handleRotation:)];

 rot.cancelsTouchesInView = NO;
rot.delegate = self;
 UIPinchGestureRecognizer *pinch =[[UIPinchGestureRecognizer alloc] initWithTarget:self
 action:@selector(handlePinch:)];
 pinch.cancelsTouchesInView = NO;
pinch.delegate = self;
/* UIPanGestureRecognizer *pan = [[UIPanGestureRecognizer alloc] initWithTarget:self
 action:@selector(handlePan:)];
 pan.cancelsTouchesInView = NO;
pan.delegate = self;*/


//circle gesture
gr = [[MDCircleGestureRecognizer alloc] init];
[gr addTarget:self action:@selector(handleGesture:)];
//[self.view  addGestureRecognizer:gr];
//gr.delegate = (id<MDCircleGestureFailureDelegate>)self.view;
gr.delegate = self;
gr.cancelsTouchesInView = NO;

////Z gesture
cg = [[CharGesture alloc] initWithTarget:self action:@selector(zLetterMade:)];
cg.delegate=self;
cg.cancelsTouchesInView = NO;
//Add on window - RR
[[[UIApplication sharedApplication]delegate]window].gestureRecognizers = @[gr,cg,pinch,rot];
uiRotationGestureRecognitzer*rot=[[uiRotationGestureRecognitzer alloc]initWithTarget:self action:@selector(HandlerRotation:)];
rot.cancelsTouchesInView=否;
rot.delegate=self;
UIPinchGestureRecognizer*pinch=[[UIPinchGestureRecognizer alloc]initWithTarget:self
操作:@选择器(handlePinch:)];
pinch.cancelsTouchesInView=否;
代表=自我;
/*UIPangestureRecognitor*pan=[[UIPangestureRecognitor alloc]initWithTarget:self
操作:@selector(handlePan:)];
pan.cancelsTouchesInView=否;
pan.delegate=self*/
//圆圈手势
gr=[[MDCirclegestureRecognitor alloc]init];
[gr addTarget:self action:@selector(HandleTesture:)];
//[self.view addgestureRecognitor:gr];
//gr.delegate=(id)self.view;
gr.代表=自我;
gr.cancelsTouchesInView=否;
////Z手势
cg=[[CharGesture alloc]initWithTarget:自我操作:@selector(zLetterMade:)];
cg.代表=自我;
cg.cancelsTouchesInView=否;
//附加窗口-RR
[[[UIApplication sharedApplication]delegate]窗口]。手势识别器=@[gr、cg、pinch、rot];

请确认您已给出
UIgestureRecognitizerDelegate
并启用交互
[[UIApplication sharedApplication]delegate]窗口].userInteractionEnabled=YES

请确认您已给出
UIgestureRecognitizerDelegate
并启用交互
[[UIApplication sharedApplication]delegate]窗口].userInteractionEnabled=YES