Reputation: 41
I have a UIView tha contain a ToolBar,and I add some BarButtonItem on the ToolBar. Now I want to hide the BarButtonItem in some time ,and display them in some time ,how can i accomplish it ??
Upvotes: 1
Views: 644
Reputation: 1684
Change your toolbar.items
accordingly.
For example if you had toolbar.items
set to [NSArray arrayWithObjects: button1, button2, nil]
and you need to hide button1, do toolbar = [NSArray arrayWithObject: button2]
Upvotes: 6