4
我是通過編程方式添加子視圖的。每個子視圖我加入手勢reconognizer:如何知道是否已將UITapGestureRecognizer添加到子視圖
UIImageView *imageView = [[UIImageView alloc] initWithImage:image];
imageView.frame = CGRectMake((position*1024)+200,0,image.size.width,image.size.height);
UITapGestureRecognizer *singleFingerTap = [[UITapGestureRecognizer alloc]
initWithTarget:self action:@selector(singleFingerTap:)];
singleFingerTap.numberOfTapsRequired = 1;
[imageView addGestureRecognizer:singleFingerTap];
[singleFingerTap release];
但水龍頭沒有響應我怎麼能確認手勢已經將其添加到子視圖?
想要獲取視圖水龍頭的屬性。如何實現此方法: - (void)viewTap:(UIGestureRecognizer *)發件人 – Juan