Created
January 2, 2014 10:20
-
-
Save koromiko/8217320 to your computer and use it in GitHub Desktop.
detect touch event
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event{ | |
UITouch *touch = [touches anyObject]; | |
CGPoint touchPoint = [touch locationInView:self]; | |
/* if touch point inside the konogram image */ | |
if(CGRectContainsPoint(self.magCoverImageView.frame, touchPoint)){ | |
if(self.delegate!=nil && [self.delegate respondsToSelector:@selector(didClickOnImageForNewIssueCell:)]){ | |
[self.delegate didClickOnImageForNewIssueCell:self]; | |
} | |
} | |
[super touchesEnded:touches withEvent:event]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment