我在我的收藏视图中使用 UILongPressGestureRecognizer,我希望长按手势识别器只有在满足特定条件时才能工作。
NSString *check;
if([check isEqualToString:@"Enabled"]
{
//long press should be detected. or following method should be called
}
-(void)handleLongPressGesture:(UILongPressGestureRecognizer *)gestureRecognizer
{
}