adding custom property to CAAnimation

* override copyWithZone:

@interface MyLayerAnimation : CABasicAnimation
{
    MyItemLayer *relatedLayer;
}
@property (assign) __weak MyItemLayer *relatedLayer;

@end


@implementation MyLayerAnimation

@synthesize relatedLayer;

- (id)copyWithZone:(NSZone *)zone
{
    MyLayerAnimation *newObj = [super copyWithZone:zone];
    newObj.relatedLayer = self.relatedLayer;
    return newObj;
}

@end

contact: form / email / +33 6 49 52 84 01