如何制作& quot; suckEffect""在iPhone的左上角? [英] How to make "suckEffect" to the left corner of iPhone?
问题描述
// Begin Animation "suckEffect".
CATransition* animation = [CATransition animation];
animation.type = @"suckEffect";
animation.duration = 1.0f;
animation.timingFunction = UIViewAnimationCurveEaseInOut;
myView.opaque = 1.0f;
[myView.layer addAnimation:animation forKey:@"transitionViewAnimation"];
当我按下删除按钮时,如何看到我编写的一段代码使动画变得生动起来.当我在应用程序中按下删除按钮时,将发生"suckEffect".但它会出现在屏幕的左上角.我想问你,除了我的iphone屏幕的左上角,是否有人知道我该怎么做!
How you can see I write a part of code witch make an animated when I press delete button. When I press delete button in my application the "suckEffect" take place. But it goes to left corner of the screen. I want to ask you if anybody know how can I do this effect but for left corner of my iphone screen !!!
推荐答案
您可以使用未公开的 + [UIView setAnimationPosition:].请注意,suckEffect没有记录,Apple会拒绝使用它的应用程序.与 setAnimationPosition:
相同.
You can use the undocumented +[UIView setAnimationPosition:]. Beware that the suckEffect is undocumented and Apple will reject apps using it. Same for setAnimationPosition:
.
这篇关于如何制作& quot; suckEffect""在iPhone的左上角?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!