【发布时间】:2015-02-14 13:25:26
【问题描述】:
我为从屏幕底部滑动的 uiview 创建了动画,但我希望在视图滑动到屏幕后禁用 bg 视图并使用这样的深色 bg:
我该怎么做?此外,当我点击深色透明视图时,我希望它滑出并启用 bg 视图。
这就是我做滑动动画的方式:
- (void)actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex {
if (buttonIndex == 0) {
} else if (buttonIndex == 1) {
self.slidingView.hidden = NO;
[UIView beginAnimations:nil context:NULL];
[UIView setAnimationDuration:0.3];
[UIView setAnimationCurve:UIViewAnimationCurveEaseInOut];
self.slidingView.frame = CGRectMake(0,0,320,20);
self.view.frame = CGRectMake(0,0,320,460);
[UIView commitAnimations];
self.view.userInteractionEnabled = NO;
}
}
谢谢
【问题讨论】:
标签: ios objective-c uiview uiviewanimationtransition