开发者

iPad: Custom Toolbar for UISplitViewController

开发者 https://www.devze.com 2023-01-13 12:02 出处:网络
How exactly does one go about implementing a custom toolbar for the main table view section of a split view?

How exactly does one go about implementing a custom toolbar for the main table view section of a split view?

The program I am writing for the iPad is landscape only so the split view has a static table view along the left side, and at the top is the toolbar with a title. It is this toolbar I would like to change. I have created the split view controller, table view开发者_JAVA百科 controller, and detail view controllers programmatically so I should have reference to the toolbar object. The only thing is I don't know how to reference it so I can overwrite it with my custom toolbar.

Is it the split view controller that creates this toolbar? Or the table view?

Any ideas?


It's a navigation bar, not a toolbar. You'll want to investigate the navigationItem property of the UIViewController responsible for the view with the navigation bar. This is an instance of UINavigationItem; see the documentation here: UINavigationItem.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号