I have some sharing code that works fine for iOS 7, but as of iOS 8, no longer works.
@IBAction func onShareButton(sender: UIButton) {
let movie = NSBundle.mainBundle().URLForResource("IMG_0564", withExtension: "mp4")!
let items = [movie]
let activity = UIActivityViewController(activityItems: items, applicationActivities: nil)
if activity.respondsToSelector("popoverPresentationController") {
activity.popoverPresentationController?.sourceView = sender
}
self.presentViewController(activity, animated: true, completion: nil)
}
As I stated, this is working fine in iOS 7, but as of iOS 8, the video clip is no longer attached to the post (or visible in the share panel) when I choose to share to Facebook. All other options work, Mail, Save to Video, AirDrop, etc all seem to work fine.
I've also tried passing the items as AVAssets:
let items = [movie].map { AVAsset.assetWithURL($0) }
and NSData:
let items = [movie].map { NSData(contentsOfURL: $0) }
Neither of which had any effect on the problem.
The problem also occurs if I use the moral equivalent in Objective-C, it's language agnostic.