【发布时间】:2013-01-08 07:51:26
【问题描述】:
当我使用 presentModalViewController
时按钮操作不起作用在视图 1 中:
-
(void)PreseentTheNextView
{
NSLog(@"clicked to add the new view from botom to top");
PreferenceViewController *prefDetails=[[PreferenceViewController alloc] initWithNibName:@"PreferenceViewController" bundle:nil];
[self presentModalViewController:prefDetails animated:YES];
}
我在 PreferenceViewController
上有两个按钮在视图 2 中:
-(IBAction)button1Click
{
NSLog(@"Button 1 Clicked");
}
-(IBAction)button2Click
{
NSLog(@"Button 2 Clicked");
}
-(IBAction)DismissButton
{
NSLog(@"Remove/ Dismiss down the view to previus page ");
}
所有这些按钮都在 PreferenceViewController 的 IB 中设置。
当我使用 presentModalViewController
时,这些按钮操作不起作用如果我使用 Navigation PushViewController 效果很好。
但我们的要求只是从下到上呈现视图
【问题讨论】:
标签: iphone objective-c presentmodalviewcontroller ibaction