【发布时间】:2010-09-20 09:17:31
【问题描述】:
我正在使用以下代码,但子视图添加在父视图下方而不是父视图(self.view)..有什么帮助吗?
-(IBAction)okbutton:(id)sender
{
obj = [[imgViewNextController alloc] initWithNibName:@"green" bundle:nil];
obj.view.frame = self.view.frame;
[UIView beginAnimations:@"curldown" context:nil];
[UIView setAnimationDelegate:self];
[UIView setAnimationDuration:.5];
[UIView setAnimationTransition:UIViewAnimationTransitionCurlDown forView:self.view cache:YES];
[self.view addSubview:obj.view];
//[self.view insertSubview:obj.view aboveSubview:self.view];
[UIView commitAnimations];
【问题讨论】:
标签: iphone ipad uiview addsubview