title: Why UITapGestureRecognizer is not Work For UIImageView?
body: <p>I have added Simple <code>UITapGestureRecognizer</code> to <code>UIImageView</code> and created <strong><em>Gesture Method</em></strong> that gets called when user <strong><em>taps/touches</em></strong> <code>UIImageView</code></p>
  
  <p><strong>My Code IS :</strong></p>
  
  <pre><code>UITapGestureRecognizer *eagleTapGesture = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(eagleTapGestureIsCall:)];
  eagleTapGesture.numberOfTapsRequired = 1;
  [self.egaleImgView addGestureRecognizer:eagleTapGesture]; 
  </code></pre>
  
  <p><strong>Gesture Method:</strong> </p>
  
  <pre><code>- (void)eagleTapGestureIsCall:(UITapGestureRecognizer *)recognizer
  {
      CGPoint location = [recognizer locationInView:[recognizer.view superview]];
      NSLog(@"Eagle is Tapped X - %f",location.x);
      NSLog(@"Eagle is Tapped Y - %f",location.y);
  }
  </code></pre>
  
  <p>Here If I add Gesture on <code>UIView</code> instead of <code>self.egaleImgView</code> then it works <em>(I mean Gesture Method is called)</em> but why it is not working on <code>self.egaleImgView</code> ???</p>
  
  <p>After Googling I found that, might be <code>UIView</code> intercepts the touches before they can reach <code>UIImageView</code>.</p>
  
  <p>So I added the following line at start of <code>viewDidLoad</code></p>
  
  <pre><code>self.view.userInteractionEnabled = NO; /// Here i set userInteractionEnabled = NO;
  </code></pre>
  
  <p>Following describes structure for better understanding.</p>
  
  <pre><code>                main UIView
                    |     |
  
  (Sub view) mainBackGroungImageView //// size is similar to size of main UIView
                    |     |
          (Sub view) gestureAdded ImageView 
  </code></pre>
  
  <p><strong>EDITED:</strong></p>
  
  <p>Sorry guys for forgetting to mention that I already added <code>self.egaleImgView.userInteractionEnabled = YES;</code> to my imageView, but it is not working for me.</p>
  
  <p>Please give me suggestions on my issue.</p>
  
  <p>Thanks in advance.</p>