Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Add an extra share button to mave
MaveSDK *mave = [MaveSDK sharedInstance];
[mave presentInvitePageModallyWithBlock:^(UIViewController *inviteController) {
if ([inviteController isKindOfClass:[UINavigationController class]]) {
UINavigationController *navController = (UINavigationController *)inviteController;
// Here replace the method "foo" with your method to present a share sheet
// And you can of course use a button with an image instead of the title "Share"
UIBarButtonItem *shareButton = [[UIBarButtonItem alloc] initWithTitle:@"Share"
style:UIBarButtonItemStylePlain
target:self action:@selector(foo)];
navController.topViewController.navigationItem.rightBarButtonItem = shareButton;
}
[self presentViewController:inviteController animated:YES completion:nil];
} dismissBlock:^(UIViewController *controller, NSUInteger numberOfInvitesSent) {
[controller dismissViewControllerAnimated:YES completion:nil];
} inviteContext:@"home-page-modal"];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.