On Tue, Apr 2, 2013, at 12:07 PM, David Duncan wrote:
> On Apr 2, 2013, at 12:04 PM, Steve Mills <sjmi...@mac.com> wrote:
> 
> > On Apr 2, 2013, at 13:49, David Duncan <david.dun...@apple.com> wrote:
> > 
> >> By default a UIView will disable animations on its layer via the CALayer 
> >> informal delegate protocol (if you are creating this layer yourself, you 
> >> should not assign a UIView subclass as its delegate). This is why you 
> >> aren't seeing implicit animations when you set the layer's position. You 
> >> should either use UIView's animation APIs (if this layer belongs to a 
> >> UIView) or you should assign something else as the layer's delegate (I 
> >> would probably recommend the former).
> > 
> > UIView? On OS X?
> 
> 
> So sorry, this question comes up so often on iOS I went into auto-pilot
> mode :). I don't know what the deal is with NSView, but I would imagine
> something similar might happen on OS X too, but I haven't looked at this
> specific behavior in a long time now.

Yes, it is similar. On 10.8, NSView's implementation of CALayer delegate
methods mirrors that of UIView's on iOS. -[NSView
actionForLayer:forKey:] returns NSNull if the current NSAnimationContext
returns NO from -allowsImplicitAnimation.

You should not make an NSView instance the delegate of a CALayer that is
not the view's layer.

--Kyle Sluder
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to