Re: CAShapeLayer and touches?
Re: CAShapeLayer and touches?
- Subject: Re: CAShapeLayer and touches?
- From: "Eric E. Dolecki" <email@hidden>
- Date: Tue, 8 Dec 2009 15:47:00 -0500
Basically if a user touches the shape layer's path (the UI for the pointer),
I'd like the user to be able to slide it left and right. I did not subclass
UIView - I am using a rootLayer and using the path within that.
CAShapeLayers have hitTests? I haven't seen code like that anywhere yet
(Google). Any help appreciated.
On Tue, Dec 8, 2009 at 3:01 PM, David Duncan <email@hidden> wrote:
> On Dec 8, 2009, at 11:34 AM, Eric E. Dolecki wrote:
>
> > Looks like that method expects a UIView - what's the best way to access
> the
> > CAShapeLayer to know whether or not a user's touched it? Then I'd like to
> > constrain drag it.
>
>
> Are you trying to hit test against the shape layer's path? I'm not certain
> that is trivial. Does the shape layer have an associated view (i.e. did you
> subclass UIView to override +layerClass)? If so you could use that
> associated view. Otherwise you can use the layer's -hitTest: method to
> determine which layer was hit.
> --
> David Duncan
> Apple DTS Animation and Printing
>
>
--
http://ericd.net
Interactive design and development
_______________________________________________
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