I have this code for when the user presses a button:
SettingsViewController *settingsViewController = [[SettingsViewController alloc] init];
WEPopoverController *popover = [[WEPopoverController alloc] initWithContentViewController:settingsViewController];
[popover setDelegate:self];
[popover presentPopoverFromRect:settingsWheel.frame
inView:self.view
permittedArrowDirections:UIPopoverArrowDirectionUp
animated:YES];
[popover setPopoverContentSize:CGSizeMake(150, 200)];
Then in settings view controller, I have this:
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
if (self) {
self.view.backgroundColor = [UIColor blueColor];
self.contentSizeForViewInPopover = CGSizeMake(150, 200);
}
return self;
}
But for some unknown reason, it’s only showing the blue square of the background and not the arrowhead, or rounded corners.
Any ideas how I get it to show these?
Below is the code for appearing the Popover (i have taken from WEPopoverTableView class on github)