社交分享完成后开始Segue
Start Segue After Completion Of Social Sharing
我想让用户在社交框架的帮助下从我的应用中分享一些 post。但是在社交框架中的 post 按钮之后,segue 没有开始。我该如何处理?
var shareToFacebook : SLComposeViewController = SLComposeViewController(forServiceType: SLServiceTypeFacebook)
shareToFacebook.addImage(self.Img.image)
self.presentViewController(shareToFacebook, animated: true, completion: nil)
self.performSegueWithIdentifier("goToStarting", sender: self)
您必须在此方法中呈现视图控制器
var completionHandler: SLComposeViewControllerCompletionHandler!
你可以这样使用上面的方法
var shareToFacebook : SLComposeViewController = SLComposeViewController(forServiceType: SLServiceTypeFacebook)
shareToFacebook.addImage(self.Img.image)
shareToFacebook.completionHandler = {
(result:SLComposeViewControllerResult) in
}
self.presentViewController(shareToFacebook, animated: true, completion: nil)
self.performSegueWithIdentifier("goToStarting", sender: self)
我想让用户在社交框架的帮助下从我的应用中分享一些 post。但是在社交框架中的 post 按钮之后,segue 没有开始。我该如何处理?
var shareToFacebook : SLComposeViewController = SLComposeViewController(forServiceType: SLServiceTypeFacebook)
shareToFacebook.addImage(self.Img.image)
self.presentViewController(shareToFacebook, animated: true, completion: nil)
self.performSegueWithIdentifier("goToStarting", sender: self)
您必须在此方法中呈现视图控制器
var completionHandler: SLComposeViewControllerCompletionHandler!
你可以这样使用上面的方法
var shareToFacebook : SLComposeViewController = SLComposeViewController(forServiceType: SLServiceTypeFacebook)
shareToFacebook.addImage(self.Img.image)
shareToFacebook.completionHandler = {
(result:SLComposeViewControllerResult) in
}
self.presentViewController(shareToFacebook, animated: true, completion: nil)
self.performSegueWithIdentifier("goToStarting", sender: self)