3
我有下面的代码,我添加UITapGestureRecognizer我的看法:UIButtons UITapGestureRecognizer后,将无法正常工作添加
UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self
action:@selector(userTapped)];
[self.view addGestureRecognizer:tap];
我的问题是,当我按其它UIButton
S(按钮是在IB创建)与UITapGestureRecognizer
的观点相同,没有任何反应。
我想我只向gestureRecognizer添加一个动作(userTapped :),但是如何添加与创建的其他按钮的交互?
我的想法是未来:我需要创建一些backgroundVIew,并在其中添加GestureRecognizer – ignotusverum 2012-04-21 16:16:50