API  0.9.6
 All Classes Files Functions Variables Macros Modules Pages
CPViewAnimation Class Reference

#import <CPViewAnimation.h>

+ Inheritance diagram for CPViewAnimation:

Instance Methods

(id) - initWithViewAnimations: 
 
(void) - setCurrentProgress: 
 
(void) - setViewAnimations: 
 
(void) - startAnimation 
 
(void) - stopAnimation 
 
(CPArray) - viewAnimations 
 
- Instance Methods inherited from CPAnimation
(CPAnimationCurve) - animationCurve 
 
(void) - animationTimerDidFire: 
 
(float) - currentProgress 
 
(float) - currentValue 
 
(id) - delegate 
 
(CPTimeInterval) - duration 
 
(float) - frameRate 
 
(id) - initWithDuration:animationCurve: 
 
(BOOL) - isAnimating 
 
(void) - setAnimationCurve: 
 
(void) - setCurrentProgress: 
 
(void) - setDelegate: 
 
(void) - setDuration: 
 
(void) - setFrameRate: 
 
- Instance Methods inherited from CPObject
(void) - addObserver:forKeyPath:options:context: 
 
(void) - applyChange:toKeyPath: 
 
(id) - autorelease 
 
(id) - awakeAfterUsingCoder: 
 
(void) - awakeFromCib 
 
(void) - bind:toObject:withKeyPath:options: 
 
(Class) - classForCoder 
 
(Class) - classForKeyedArchiver 
 
(CPString) - className 
 
(id) - copy 
 
(void) - dealloc 
 
(CPString) - description 
 
(CPDictionary) - dictionaryWithValuesForKeys: 
 
(void) - didChange:valuesAtIndexes:forKey: 
 
(void) - didChangeValueForKey: 
 
(void) - didChangeValueForKey:withSetMutation:usingObjects: 
 
(void) - doesNotRecognizeSelector: 
 
(CPArray) - exposedBindings 
 
(id) - forwardingTargetForSelector: 
 
(void) - forwardInvocation: 
 
(unsigned) - hash 
 
(BOOL) - implementsSelector: 
 
(CPDictionary) - infoForBinding: 
 
(id) - init 
 
(BOOL) - isEqual: 
 
(BOOL) - isKindOfClass: 
 
(BOOL) - isMemberOfClass: 
 
(BOOL) - isProxy 
 
(IMP) - methodForSelector: 
 
(CPMethodSignature) - methodSignatureForSelector: 
 
(id) - mutableArrayValueForKey: 
 
(id) - mutableArrayValueForKeyPath: 
 
(id) - mutableCopy 
 
(id) - mutableSetValueForKey: 
 
(id) - mutableSetValueForKeyPath: 
 
(id) - performSelector: 
 
(id) - performSelector:withObject: 
 
(id) - performSelector:withObject:withObject: 
 
(id) - performSelector:withObjects: 
 
(void) - release 
 
(void) - removeObserver:forKeyPath: 
 
(id) - replacementObjectForArchiver: 
 
(id) - replacementObjectForCoder: 
 
(id) - replacementObjectForKeyedArchiver: 
 
(BOOL) - respondsToSelector: 
 
(id) - retain 
 
(id) - self 
 
(void) - setValue:forKey: 
 
(void) - setValue:forKeyPath: 
 
(void) - setValue:forUndefinedKey: 
 
(void) - setValuesForKeysWithDictionary: 
 
(CPString) - UID 
 
(void) - unbind: 
 
(Class) - valueClassForBinding: 
 
(id) - valueForKey: 
 
(id) - valueForKeyPath: 
 
(id) - valueForUndefinedKey: 
 
(void) - willChange:valuesAtIndexes:forKey: 
 
(void) - willChangeValueForKey: 
 
(void) - willChangeValueForKey:withSetMutation:usingObjects: 
 

Additional Inherited Members

- Class Methods inherited from CPObject
(BOOL) + accessInstanceVariablesDirectly 
 
(id) + alloc 
 
(id) + allocWithCoder: 
 
(BOOL) + automaticallyNotifiesObserversForKey: 
 
(Class) + class 
 
(void) + exposeBinding: 
 
(void) + initialize 
 
(IMP) + instanceMethodForSelector: 
 
(BOOL) + instancesRespondToSelector: 
 
(BOOL) + isSubclassOfClass: 
 
(CPSet) + keyPathsForValuesAffectingValueForKey: 
 
(void) + load 
 
(id) + new 
 
(void) + setVersion: 
 
(Class) + superclass 
 
(int) + version 
 
- Instance Variables inherited from CPObject
Class isa
 

Detailed Description

CPViewAnimation is a subclass of CPAnimation that makes it easy to do basic animations on views.

Definition at line 2 of file CPViewAnimation.h.

Method Documentation

- (id) initWithViewAnimations: (CPArray)  viewAnimations
implementation

Designated initializer.

This method takes an array of CPDictionaries. Each dictionary should contain values for the following keys:

CPViewAnimationTargetKey - (Required) The view to animate.
CPViewAnimationStartFrameKey - (Optional) The start frame of the target.
CPViewAnimationEndFrameKey - (Optional) The end frame of the target.
CPViewAnimationEffectKey - (Optional) a fade effect to use for the animation.

For example:

var animation = [CPDictionary dictionaryWithObjects:[myViewToAnimate, aStartFrame, anEndFrame, CPViewAnimationFadeInEffect]
                                            forKeys:[CPViewAnimationTargetKey, CPViewAnimationStartFrameKey, CPViewAnimationEndFrameKey, CPViewAnimationEffectKey]];

If you pass nil instead of an array of dictionaries you should later call setViewAnimations:.

Parameters
viewAnimations- An array of CPDictionaries for each animation.

Definition at line 68 of file CPViewAnimation.j.

- (void) setCurrentProgress: (CPAnimationProgress)  progress
implementation

Definition at line 102 of file CPViewAnimation.j.

- (void) setViewAnimations: (CPArray)  viewAnimations
implementation

Takes an array of CPDictionaries as documented in initWithViewAnimations:.

Parameters
viewAnimations- An array of dictionaries describing the animation.

Definition at line 219 of file CPViewAnimation.j.

- (void) startAnimation
implementation

Starts the animation. The method calls -animationShouldStart: on the delegate (if it implements it) to see if the animation should begin.

Reimplemented from CPAnimation.

Definition at line 78 of file CPViewAnimation.j.

- (void) stopAnimation
implementation

Stops the animation before it has completed.

Reimplemented from CPAnimation.

Definition at line 141 of file CPViewAnimation.j.

- (CPArray) viewAnimations
implementation

Definition at line 209 of file CPViewAnimation.j.


The documentation for this class was generated from the following files: