Re: Controlling some of CoreAnimation's more confusing automation
Re: Controlling some of CoreAnimation's more confusing automation
- Subject: Re: Controlling some of CoreAnimation's more confusing automation
- From: David Duncan <email@hidden>
- Date: Thu, 21 May 2009 10:09:38 -0700
On May 20, 2009, at 7:04 PM, Gwynne Raskind wrote:
I have a UIView that contains a number of CALayers. Nothing unusual
here. The CALayers are subclassed to do their drawing, because that
was easier than separating the delegate logic from my UIView
subclass (since the view can't be the delegate of a sublayer - it
causes an infinite recursion to do so, why isn't there a check for
this somewhere in CA's or Cocoa Touch's code?).
UIKit expects that a view and layer are tightly coupled and that the
view is not a shared delegate between multiple layers, period. Even if
it worked, you would see a lot of behavior that you may not desire by
setting a view as a layer's delegate.
1) animate the custom properties more directly with a
CABasicAnimation. I tried this, but it did nothing at all.
Custom property animation is not supported on iPhone OS 2.x or Mac OS
X 10.5.
2) get some control over the implicit animation CA is setting up for
the contents transition. CATransaction only lets me set duration and
the "is enabled" flag, whereas CAMediaTiming has a whole pile of
useful parameters.
You can change the default animation for any property of a layer. See
the documentation for -actionForKey: for more information.
--
David Duncan
Apple DTS Animation and Printing
_______________________________________________
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