Mas*_*adi 2 animation cocoa-touch image objective-c ipad
嗨,我正在研究iPhone应用程序,我必须动画和旋转图像,图像附在这里 
现在这个图像的目的是,无论何时在iPad上任何地方点击它都会有动画并指向那个地方.
请帮我搞清楚.感谢名单
试试这个 -
CABasicAnimation* animation = [CABasicAnimation animationWithKeyPath:@"transform.rotation.z"];
animation.fromValue = [NSNumber numberWithFloat:0.0f];
animation.toValue = [NSNumber numberWithFloat: 2*M_PI];
animation.duration = 10.0f;
animation.repeatCount = INFINITY;
[self.yourImage.layer addAnimation:animation forKey:@"SpinAnimation"];
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
7793 次 |
| 最近记录: |