Using the "Social" Framework, when presenting the modal UIActivityViewController that displays all the usual social-media icons, is there a way to find out exactly which icon the user clicked on? Meaning, if they chose Twitter, Facebook, Mail, Message, etc?
I was expecting to possibly see some delegate methods for this class in the Docs but I don't see anything.
Anybody got any ideas?
The UIActivityViewController
has the completionHandler
property. Implement this handler to be notified.
UIActivityViewController *avc = ...;
avc.completionHandler = ^(NSString *activityType, BOOL completed) {
if (completed) {
NSLog(@"The selected activity was %@", activityType);
}
};