是否可以在弹出框内的 UIViewController 中显示工具栏项?我在我的视图控制器的 viewDidLoad 方法中这样做:
UIBarButtonItem *addButton = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemAdd target:nil action:nil];
[self setToolbarItems:[NSArray arrayWithObject:addButton]];
[addButton release];
然后我将这个视图控制器包装在一个UINavigationController
(它有一个toolbar
属性,根据文档,我应该使用向工具栏添加项目的setToolbarItems
方法UIViewController
),然后在弹出窗口中呈现它。
我没有看到工具栏。使用弹出框时是否不支持工具栏?
谢谢