ActionsViewController *actionsViewController = [AppLibrary createActionsViewController];
actionsViewController.actionDelegate = self;
actionsViewController.supportedActionTypes = @[[[SupportedAction alloc] initWithActionType:ActionTypeEdit mediaTypes:@[kTypePNG]]];
[actionsViewController setWhitelistedSubTypes:@[@"adjust", @"filter", @"healing"]];
if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone) {
self.actionsNavigationController = [[UINavigationController alloc] initWithRootViewController:actionsViewController];
[self presentViewController:self.actionsNavigationController animated:YES completion:nil];
}
Asked
Active
Viewed 173 times
-2
-
1- (IBAction)go:(id)sender ; – alideny Dec 22 '15 at 05:58
-
1just how to call this code from button ? – alideny Dec 22 '15 at 06:01
-
This might help: http://stackoverflow.com/questions/5843427/how-do-you-add-an-action-to-a-button-programmatically-in-xcode. In the button event, you can paste your required code for functionality. – Mrunal Dec 22 '15 at 06:09
1 Answers
1
just add this in
-(IBAction)go:(id)sender
{
ActionsViewController *actionsViewController = [AppLibrary createActionsViewController];
actionsViewController.actionDelegate = self;
actionsViewController.supportedActionTypes = @[[[SupportedAction alloc] initWithActionType:ActionTypeEdit mediaTypes:@[kTypePNG]]];
[actionsViewController setWhitelistedSubTypes:@[@"adjust", @"filter", @"healing"]];
if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone) {
self.actionsNavigationController = [[UINavigationController alloc] initWithRootViewController:actionsViewController];
[self presentViewController:self.actionsNavigationController animated:YES completion:nil];
}
}
Please check the following Doc: Apple Doc

Smile
- 667
- 1
- 5
- 21