IFTTT/JazzHands

Can not re-implement Demo because source file change?

wongzigii opened this issue · 0 comments

I am trying to re-implement the Demo which the compiler warns me Assignment to readonly property
at the line of code:

- (void)configureAnimation
{
    IFTTTFrameAnimation *wordmarkFrameAnimation = [IFTTTFrameAnimation new];
    wordmarkFrameAnimation.view = self.firstPerson;
                          ^^^^
    [self.animator addAnimation:wordmarkFrameAnimation];
}

I noticed that the IFTTTAnimation.h class in Demo looks like:

@interface IFTTTAnimation : NSObject

@property (strong, nonatomic) UIView *view;
@property (strong, nonatomic) NSMutableArray *keyFrames;

- (id)initWithView:(UIView *)view;

- (void)animate:(NSInteger)time;
- (void)addKeyFrame:(IFTTTAnimationKeyFrame *)keyFrame;

- (IFTTTAnimationFrame *)animationFrameForTime:(NSInteger)time;
- (CGFloat)tweenValueForStartTime:(NSInteger)startTime
                      endTime:(NSInteger)endTime
                   startValue:(CGFloat)startValue
                     endValue:(CGFloat)endValue
                       atTime:(CGFloat)time;

view is a readwrite type property, while in the newest pod, the IFTTTViewAnimation class :

@interface IFTTTViewAnimation : IFTTTAnimation

@property (nonatomic, strong, readonly) UIView *view;

- (instancetype)initWithView:(UIView *)view;
+ (instancetype)animationWithView:(UIView *)view;

@end

view is a readonly property. Any idea?