uiactivityviewcontroller

NSArray* excludedActivities Leaks memory even when using ARC and setting it to nil

坚强是说给别人听的谎言 提交于 2019-12-24 15:27:09
问题 I'm trying to use the new iOS6 UIActivityViewController and it works fine except that the Memory Leaks instrument says that the NSArray *execludedActivities is leaking every time I try to show the controller. Note that I tried to use an NSArray called excludedActivities and then set the shareShareController.excludedActivityTypes to be able to set the array to nil later (all that is commented code below) but now I'm setting the property directly and still there is a leak. - (IBAction)share:(id

iOS UIActivityViewController using UIActivityItemProvider “forgets” items

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-24 12:30:16
问题 I have a larger app that should be able to share multiple images. I implemented this using UIActivityViewController and UIActivityItemProvider to have asynchronous usage of the items (so that i only have to prepare one image at a time and not have to fill the memory with all of them at once to share them). I was "inspired" by the Apple Airdrop example: AirdropSample download However when using my app to share e.g. 9 images (to camera Roll == "Save 9 images") only 4 to 7 images end up being in

Is there maximum file or image size for twitter or Facebook via UIActivityViewController?

ⅰ亾dé卋堺 提交于 2019-12-24 05:35:22
问题 I use UIActivityViewController to share images and text to Message, Email, Facebook, Twitter etc. Until recently, I thought I could send images of any size (at least up to 5MB). However, I have noticed that I can no longer send images greater than say 2.5MB to Facebook or twitter. E.g., I select an image to share, open the activityViewController and select Facebook. The activityViewController slowly opens the Facebook interface/view (but doesn't show attached image) then closes the Facebook

SwiftUI exporting or sharing files

筅森魡賤 提交于 2019-12-24 03:07:09
问题 I'm wondering if there is a good way export or share a file through SwiftUI. There doesn't seem to be a way to wrap a UIActivityViewController and present it directly. I've used the UIViewControllerRepresentable to wrap a UIActivityViewController, and it crashes if I, say, present it in a SwiftUI Modal. I was able to create a generic UIViewController and then from there call a method that presents the UIActivityViewController, but that's a lot of wrapping. And if we want to share from the Mac

No Title or Cancel Button for MFMessageComposeViewController

怎甘沉沦 提交于 2019-12-24 00:58:28
问题 I'm trying to present a MFMessageComposeViewController from a UIActivityViewController. However, when I select to share using a Message I see this let activityVC = UIActivityViewController(activityItems: ["text"], applicationActivities: nil) self.presentViewController(activityVC, animated: true, completion: nil) I customized my navigation bar appearance in my AppDelegate UINavigationBar.appearance().barTintColor = UIColor.blackColor() UINavigationBar.appearance().tintColor = UIColor

What is the UIActivityType for Notes?

痴心易碎 提交于 2019-12-23 07:50:44
问题 I am trying to exclude all services from my UIActivityType except for email and text message. I am using the following statement: activityController.excludedActivityTypes = @[UIActivityTypeAddToReadingList,UIActivityTypeAirDrop,UIActivityTypeAssignToContact,UIActivityTypeCopyToPasteboard, UIActivityTypePostToFacebook,UIActivityTypePostToFlickr,UIActivityTypePostToTencentWeibo,UIActivityTypePostToTwitter, UIActivityTypePostToVimeo,UIActivityTypePostToWeibo,UIActivityTypePrint

UIActivityViewController on iPad

女生的网名这么多〃 提交于 2019-12-22 13:58:45
问题 I have been using the code below to show a UIActivityViewController which worked fine when I was using Xcode 6, Swift 1.2 and iOS 8. However when I updated it shows the UIActivityViewController but it is completely blank without any of the sharing options. Do you have any suggestions? if UIDevice.currentDevice().userInterfaceIdiom == .Pad { let textToShare = textViewOne.text let objectsToShare = [textToShare] let activityVC = UIActivityViewController(activityItems: objectsToShare,

UIActivityViewController on iPad

六眼飞鱼酱① 提交于 2019-12-22 13:58:10
问题 I have been using the code below to show a UIActivityViewController which worked fine when I was using Xcode 6, Swift 1.2 and iOS 8. However when I updated it shows the UIActivityViewController but it is completely blank without any of the sharing options. Do you have any suggestions? if UIDevice.currentDevice().userInterfaceIdiom == .Pad { let textToShare = textViewOne.text let objectsToShare = [textToShare] let activityVC = UIActivityViewController(activityItems: objectsToShare,

UIActivityViewController Airdrop - Check the status when 'sent' or 'declined'

一个人想着一个人 提交于 2019-12-22 12:19:13
问题 Is it possible to check if the recipient 'declined' or 'accepted' the share? I want to NSLog 'sent' if sent and NSLog 'declined' if declined by the user. 来源: https://stackoverflow.com/questions/23495399/uiactivityviewcontroller-airdrop-check-the-status-when-sent-or-declined

How can I present a ModalViewController from a UIActivity item picked from UIActivity View Controller?

陌路散爱 提交于 2019-12-22 05:33:14
问题 I am working on an app that presents some data in a detailViewController. I have a rightBarButton in the navbar that presents a UIActivityViewController that is filled with my own UIActivity sublclassed items. Most of them work fine as they are just changing a small aspect to the data from the detail view, but I need one of them to open a modalViewController when selected. I keep getting the following warning from the console..... Warning: Attempt to present <UINavigationController: