码迷,mamicode.com
首页 > 其他好文 > 详细

旋转图片

时间:2014-09-24 21:10:47      阅读:184      评论:0      收藏:0      [点我收藏+]

标签:ios

旋转图片

by 伍雪颖

- (void)startAnimation {
    CABasicAnimation* rotationAnimation;
    rotationAnimation = [CABasicAnimation animationWithKeyPath:@"transform.rotation.z"];
    rotationAnimation.toValue = [NSNumber numberWithFloat: M_PI * 2.0 ];
    rotationAnimation.duration = 1;
    rotationAnimation.cumulative = YES;
    rotationAnimation.repeatCount = 3;
    [_loadingImage.layer addAnimation:rotationAnimation forKey:@"rotationAnimation"];
}


旋转图片

标签:ios

原文地址:http://blog.csdn.net/rainlesvio/article/details/39526691

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!