Shared with You

RSS for tag

Bring your app’s collaboration experiences into Messages and FaceTime, and highlight content from your app that people shared in Messages in a Shared with You section within your app.

Posts under Shared with You tag

24 Posts

Post

Replies

Boosts

Views

Activity

How is SWCollaborationView supposed to be used in new documents (iCloud Drive)?
The Mac app I’m working on stores documents in iCloud Drive. Showing an SWCollaborationView in the toolbar works when creating an NSItemProvider using the document’s fileURL like this: if let documentURL = document.fileURL { toolbarItem.view = SWCollaborationView(itemProvider: NSItemProvider(object: documentURL)) } This only works if a document was previously saved to disk and is then opened, though, because a new, unsaved document doesn’t have a fileURL yet. So this means I can’t show an SWCollaborationView for unsaved documents. What I don’t quite understand is what we are supposed to do in this situation. The current version of Pages (which doesn’t use SWCollaborationView yet, of course) seems to show a button for collaboration for new documents and when you click that, the document is saved to iCloud without user interaction before the popover opens. How would I go about doing this in my app? And here’s also a bonus question: Do I have to handle renaming/moving of the document manually? That is, does SWCollaborationView automatically handle the case where the document is renamed in Finder/Files? I’m curious because the SWCollaborationView references an NSItemProvider which in turn references an NSURL and it’s not clear to me if that should work. And if I have to do it manually: Does this mean I’ll have to create a new SWCollaborationView and set it on my toolbar item?
0
0
1k
Jul ’22
How is SWCollaborationView supposed to be used in new documents (iCloud Drive)?
The Mac app I’m working on stores documents in iCloud Drive. Showing an SWCollaborationView in the toolbar works when creating an NSItemProvider using the document’s fileURL like this: if let documentURL = document.fileURL { toolbarItem.view = SWCollaborationView(itemProvider: NSItemProvider(object: documentURL)) } This only works if a document was previously saved to disk and is then opened, though, because a new, unsaved document doesn’t have a fileURL yet. So this means I can’t show an SWCollaborationView for unsaved documents. What I don’t quite understand is what we are supposed to do in this situation. The current version of Pages (which doesn’t use SWCollaborationView yet, of course) seems to show a button for collaboration for new documents and when you click that, the document is saved to iCloud without user interaction before the popover opens. How would I go about doing this in my app? And here’s also a bonus question: Do I have to handle renaming/moving of the document manually? That is, does SWCollaborationView automatically handle the case where the document is renamed in Finder/Files? I’m curious because the SWCollaborationView references an NSItemProvider which in turn references an NSURL and it’s not clear to me if that should work. And if I have to do it manually: Does this mean I’ll have to create a new SWCollaborationView and set it on my toolbar item?
Replies
0
Boosts
0
Views
1k
Activity
Jul ’22
How can my app know if a text message is sent to a device that has my app installed?
How can my app know if a text message is sent to a device that has my app installed? Is there a user notification or a remote notification that notifies when a text message or iMessage arrives on the device? i’m willing to try anything.
Replies
0
Boosts
0
Views
693
Activity
Jul ’22
HighlightCenter returns no links
Hi I got 2 universal links to my app in my Messages, but when I call highlightCenter.highlights, I get a count of 0. What should I check to get the right links ?
Replies
3
Boosts
0
Views
1.6k
Activity
Jun ’22
SwiftUI Support?
Hey, Loving these new API’s, and would love to integrate in my app. I could only see UIKit support within the video - is there any SwiftUI support out of the box? Cheers!
Replies
2
Boosts
1
Views
1k
Activity
Jun ’22