- (IBAction为)弹出:(ID)发送方 {
NomadPopupViewController *detailViewController = [[NomadPopupViewController alloc] init];
[self presentPopupViewController:detailViewController animationType:MJPopupViewAnimationFade];
//[self dismissPopupViewControllerWithanimationType:MJPopupViewAnimationFade];
}
获取此视图,当我单击leftnavigationbarbutton
时,我想在此视图控制器中有一个弹出菜单
想要这个观点......
答案 0 :(得分:0)
你可以试试presentViewController,我在我的一个应用程序中尝试
1)将其放在viewDidLoad()
中 self.modalPresentationStyle =
UIModalPresentationCurrentContext;
2)点击事件
Popup *v2 = [[Popup alloc]initWithNibName:@"Popup" bundle:nil];
v2.modalTransitionStyle = UIModalTransitionStyleCrossDissolve;
[self presentViewController:v2 animated:YES completion:nil];
3)使用UIViewController制作弹出窗口,因为你想要显示
完成了享受!