Skip to content

Instantly share code, notes, and snippets.

@lordbron
Created January 15, 2016 21:37
Show Gist options
  • Save lordbron/2ded8de61b5077669c9b to your computer and use it in GitHub Desktop.
Save lordbron/2ded8de61b5077669c9b to your computer and use it in GitHub Desktop.
-(void)showSignatureBoxFromButton:(UIButton*)fromButton {
UIStoryboard *sb = [UIStoryboard storyboardWithName:@"Main" bundle:nil];
PESignatureViewController *vc = [sb instantiateViewControllerWithIdentifier:@"signatureCapture"];
vc.delegate = self;
UIPopoverController* aPopover = [[UIPopoverController alloc]
initWithContentViewController:vc];
// Store the popover in a custom property for later use.
self.myPopoverController = aPopover;
[self.myPopoverController presentPopoverFromRect:fromButton.frame inView:self.view permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES];
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment