Post

Replies

Boosts

Views

Activity

Reply to Trouble with a share sheet on a sheet in iOS 15
I switched to the Activity Sheet code that I found here: https://swiftui.gallery/uploads/code/ShareSheet.html And now I've got no problem bringing up a Share Sheet over my other sheet. However, I'm having trouble getting it configured to share what I want. I'm trying to share a zip file out of my app. I've got an NSURL to the file, which I can pass with no problem, but it fails when I try to airdrop it. I assume this has something to do with applicationActivities?
Sep ’21
Reply to Creating a Share Sheet in an onDismiss handler in iOS
Found the answer: if UIDevice.current.userInterfaceIdiom == .pad {                 av.popoverPresentationController?.sourceView = UIApplication.shared.windows.first                 av.popoverPresentationController?.sourceRect = CGRect (                     x: UIScreen.main.bounds.width / 2.1,                     y: UIScreen.main.bounds.height / 2.3,                     width: 200, height: 200)
Sep ’21