0
A
回答
1
这是其在iOS系统中引入的新模块API 4.0 使用这个,如果你还没有在4.0
CABasicAnimation *theAnimation;
theAnimation=[CABasicAnimation animationWithKeyPath:@"transform.translation.x"];
theAnimation.duration=1;
theAnimation.repeatCount=2;
theAnimation.autoreverses=YES;
theAnimation.fromValue=[NSNumber numberWithFloat:0];
theAnimation.toValue=[NSNumber numberWithFloat:-60];
[view.layer addAnimation:theAnimation forKey:@"animateLayer"];
这段代码移动视图60个像素向左,然后回到它原来的位置 [请不要忘记投票,如果你发现这个答案有用:-)]
0
使用的UIView的过渡效果..
[UIView AnimateWithDuration: delay: options: animations: completion: ];
梅索德。 重复转换有一些很好的效果。
相关问题
- 1. iPhone:就像一本图画书,与removeFromSuperView
- 2. 图像帧(iPhone)的动画片段
- 3. iphone中的动画图像层
- 4. 来自图像集的iphone动画
- 5. 动画GIF图像作为iPhone的启动画面
- 6. 图像动画像
- 7. 动画图像
- 8. 动画图像
- 9. iPhone视图移动动画
- 10. 如何在iPhone中启动和停止图像动画
- 11. Xcode,iphone - 使图像动画在特定方向移动
- 12. iPhone:与核心动画
- 13. Iphone连续动画与setAnimationDelay
- 14. 在UIWebView中动画图像
- 15. 动画与cocos2d中的图像
- 16. QML闪烁与图像上的动画
- 17. 三维动画与PNG图像
- 18. iphone uipickerview与图像
- 19. 动画图像wpf
- 20. 图像不动画
- 21. J2me动画图像
- 22. iOS图像动画
- 23. Android图像动画
- 24. jquery动画图像
- 25. 动画图像js
- 26. Android:动画图像?
- 27. 动画SVG图像
- 28. UIButton图像动画
- 29. iphone图像变化与运动
- 30. iPhone多子视图动画
对不起,给我一个代码的问题一般不欢迎在这里。你必须尝试自己做一些事情,并询问你在这个过程中遇到的具体问题... – Vladimir 2010-10-21 10:32:07