Re: UITableView: Delay select recognition
Re: UITableView: Delay select recognition
- Subject: Re: UITableView: Delay select recognition
- From: Luke the Hiesterman <email@hidden>
- Date: Thu, 27 Jan 2011 10:06:17 -0800
On Jan 27, 2011, at 8:17 AM, Phillip Mills wrote:
> On 2011-01-27, at 10:42 AM, Luke Hiesterman wrote:
>
>> What is this gesture recognizer you speak of pulling out of the table view? Table view does not use gestures for selection, but you're right that even if it did, you shouldn't mess with it.
>
> For solely educational purposes, I made the (apparently incorrect) assumption that UIScrollViewDelayedTouchesBeganGestureRecognizer would be responsible for touches in the table view. Perhaps it's another trick of timing, but forcing it to wait on the outcome of my double-tap seems to do exactly what I wanted...in the simplest case I could devise, at least.
>
>> A single tap by itself would fire before the table gets a chance to process any touches. By adding the failure requirement you allow the table to get touch events when the gesture doesn't fire immediately.
>
> That's certainly what I saw. (Which once again brings up my lifelong hatred for timing-dependent code...as mentioned elsewhere. :) )
>
>> Have you tried just having a double tap gesture and doing everything there? Perform one action on the succeed case and another on the failure case.
>
> I'm not sure how that works. If my target action is called, then the double succeeded but how would I know it failed except through a dependent single succeeding? Should I be looking at the UIGestureRecognizerDelegate for that?
Knowing that it failed would require a subclass.
Luke_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden