I am just trying out pinch gesture on UILabel but it's not working. When I applied the same to UIView it works.
Below is my code:
in viewDidLoad
UIPinchGestureRecognizer *pinchLabel = [[UIPinchGestureRecognizer alloc] initWithTarget:self action:@selector(pinchLabel:)];
[pinchLabel setDelegate:self];
[_lblDouble addGestureRecognizer:pinchLabel];
-(void)pinchLabel:(UIPinchGestureRecognizer *)recognizer{
NSLog(@"jhhj"); // method never gets called. I have a breakpoint here.
}
Why is it so? Where am I getting wrong?