org.rococoa.cocoa.appkit.protocols
Interface NSAnimatablePropertyContainer._static_

All Known Implementing Classes:
NSAnimatablePropertyContainer._class_
Enclosing interface:
NSAnimatablePropertyContainer

public static interface NSAnimatablePropertyContainer._static_


Method Summary
 NSObject defaultAnimationForKey(NSString key)
          As described above, -animationForKey: consults this class method when its search of an instance's "animations" dictionary doesn't turn up an animation to use for a given property change.
 

Method Detail

defaultAnimationForKey

NSObject defaultAnimationForKey(NSString key)
As described above, -animationForKey: consults this class method when its search of an instance's "animations" dictionary doesn't turn up an animation to use for a given property change.
An animatable property container should implement +defaultAnimationForKey: to return a default animation to be performed for each key that it wants to make auto-animatable, where "key" usually names a property of the receiver, but can also specify a special animation trigger (NSAnimationTriggerOrderIn or NSAnimationTiggerOrderOut).
A developer implementing a custom view subclass, for example, can enable automatic animation the subclass' added properties by overriding this method, and having it return the desired default CAAnimation to use for each of the property keys of interest. The override should defer to super for any keys it doesn't specifically handle, facilitating inheritance of default animation specifications.
The full set of available CAAnimation classes can be found in QuartzCore/CAAnimation.h. Useful concrete animation classes are CABasicAnimation, CAKeyframeAnimation, CAAnimationGroup, and CATransition, all of which can be instantiated with default parameters by sending the class an +animation message.