You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Great project,for sure. But I have an issue when adding custom view on the GMGridViewCell object and try to perform an animation. I add one rotation animation on my image view. This image view is added on a GMGridViewCell. Animation.repeatcount is set to max ,however the repeat count is random. Could you please give me an answer how to fix this ?
Great project,for sure. But I have an issue when adding custom view on the GMGridViewCell object and try to perform an animation. I add one rotation animation on my image view. This image view is added on a GMGridViewCell. Animation.repeatcount is set to max ,however the repeat count is random. Could you please give me an answer how to fix this ?
{
GMGridViewCell *cell = [gridView dequeueReusableCell];
cell = [[GMGridViewCell alloc] init];
cell.backgroundColor = [UIColor colorWithHexStr:@"#f5f5f5" alpha:1];
NSString *sceneStr= [self.scenesArray objectAtIndex:index];
AndLinkNewRootSceneItemView *sceneItemView = [[AndLinkNewRootSceneItemView alloc] initWithFrame:CGRectMake(0, 0, cell.frame.size.width, cell.frame.size.height) scene:sceneStr];
[cell addSubview:sceneItemView];
[self.sceneItemViewList addObject:sceneItemView];
return cell;
}
#import "AndLinkNewRootSceneItemView.m"
-(void)addanimation{
CABasicAnimation *animation = [self spinAnimationWithDuration:1.0 clockwise:YES repeat:YES];
animation.delegate = self;
[self.curSceneImageView.layer addAnimation:animation forKey:@"rotationAnimation"];
}
{
CABasicAnimation *anim = [CABasicAnimation animationWithKeyPath:@"transform.rotation.z"];
anim.toValue = clockwise ? @(M_PI * 2.0) : @(M_PI * -2.0);
anim.duration = duration;
anim.cumulative = YES;
//anim.autoreverses = YES;
anim.removedOnCompletion = NO;
anim.repeatCount = repeats ? CGFLOAT_MAX : 0;
return anim;
}
the CGFLOAT_MAX doesn't work.
The text was updated successfully, but these errors were encountered: