title: Share a video and text on Twitter, Instagram and other services using UIActivityViewController
body: <p>I am trying to share a video and a text on Instagram, Facebook, Twitter and the native services like Mail, Messages, .... I can not figure out how to get both, Instagram and Twitter to show up in the sharing actionsheet:</p>
  
  <p>If i pass in an array of text and a URL as activity items into the controller, just Instagram shows up, but not Twitter.</p>
  
  <pre><code>let url: NSURL = NSURL() // a url that directs to a video
  let items: [AnyObject] = ["Check out this video", url]    
  let shareable = UIActivityViewController(activityItems: items, applicationActivities: nil)
  
  controller.presentViewController(shareable,
                                 animated: true,
                                 completion: nil)
  </code></pre>
  
  <p>If i create a class that implements the UIActivityItemSource protocol instead and use that as activityItems, just Twitter shows up, but not Instagram:</p>
  
  <pre><code>class VideoActivityItemSource: NSObject, UIActivityItemSource {
  
      private let videoUrl: NSURL
      private let shareText = "View the full video here!"
  
      init(url: NSURL) {
          self.videoUrl = url
      }
  
      func activityViewControllerPlaceholderItem(activityViewController: UIActivityViewController) -&gt; AnyObject {
          return ""
      }
  
      func activityViewController(activityViewController: UIActivityViewController, itemForActivityType activityType: String) -&gt; AnyObject? {
          switch activityType {
  
          case UIActivityTypePostToFacebook:
              return self.videoUrl
          case UIActivityTypeMail:
              return self.videoUrl
          default:
              return ["text": self.shareText, "url": self.videoUrl]
          }
      }
  
      func activityViewController(activityViewController: UIActivityViewController, subjectForActivityType activityType: String?) -&gt; String {
          return "Hey check this new cool app!!!"
      }
  
      func activityViewController(activityViewController: UIActivityViewController, thumbnailImageForActivityType activityType: String?, suggestedSize size: CGSize) -&gt; UIImage? {
          return nil
      }
  }
  </code></pre>
  
  <p>and then replace the items by this:</p>
  
  <pre><code>items = [VideoActivityItemSource(url: url)]
  </code></pre>
  
  <p>I have no idea why in this case Twitter won't show up in the action sheet. Does somebody have an idea how to solve this?</p>