Created
August 5, 2011 22:43
-
-
Save Shaolo/1128707 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (void)showRootPopoverButtonItem:(UIBarButtonItem *)barButtonItem | |
{ | |
// Add the popover button to the toolbar. | |
NSMutableArray *itemsArray = [self.toolbar.items mutableCopy]; | |
// NSAssert(barButtonItem, @"Bar button item nil"); | |
if(barButtonItem) | |
[itemsArray insertObject:barButtonItem atIndex:0]; | |
else | |
NSLog(@"Tried adding nil barButtonItem"); | |
[self.toolbar setItems:itemsArray animated:NO]; | |
[itemsArray release]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment