apollo9 apollo9 - 2 months ago 9
Objective-C Question

xcode 7.3.1 my storyboard segues to popover are mis-aligned. Objective c

If I simply drag a popover segue from a button, the arrow aligns to the top left of the button, instead of the center.

Anyone have any ideas?

Answer

I solve this problems using PopoverController, use UIPopoverControllerDelegate

myPopover = [[UIPopoverController alloc] initWithContentViewController:destinationViewController];
myPopover.delegate = self;        
[myPopover presentPopoverFromRect:((UIView *)sender).bounds inView:sender permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES];
Comments