AttachmentManagerDelegate
public protocol AttachmentManagerDelegate : AnyObject
AttachmentManagerDelegate is a protocol that can recieve notifications from the AttachmentManager
-
Can be used to determine if the AttachmentManager should be inserted into an InputStackView
Declaration
Swift
func attachmentManager(_ manager: AttachmentManager, shouldBecomeVisible: Bool)
Parameters
manager
The AttachmentManager
shouldBecomeVisible
If the AttachmentManager should be presented or dismissed
-
attachmentManager(_:didInsert:at:)
Default implementationNotifys when an attachment has been inserted into the AttachmentManager
Default Implementation
Declaration
Swift
func attachmentManager(_ manager: AttachmentManager, didInsert attachment: AttachmentManager.Attachment, at index: Int)
Parameters
manager
The AttachmentManager
attachment
The attachment that was inserted
index
The index of the attachment in the AttachmentManager’s attachments array
-
attachmentManager(_:didRemove:at:)
Default implementationNotifys when an attachment has been removed from the AttachmentManager
Default Implementation
Declaration
Swift
func attachmentManager(_ manager: AttachmentManager, didRemove attachment: AttachmentManager.Attachment, at index: Int)
Parameters
manager
The AttachmentManager
attachment
The attachment that was removed
index
The index of the attachment in the AttachmentManager’s attachments array
-
attachmentManager(_:didReloadTo:)
Default implementationNotifys when the AttachmentManager was reloaded
Default Implementation
Declaration
Swift
func attachmentManager(_ manager: AttachmentManager, didReloadTo attachments: [AttachmentManager.Attachment])
Parameters
manager
The AttachmentManager
attachments
The AttachmentManager’s attachments array
-
attachmentManager(_:didSelectAddAttachmentAt:)
Default implementationNotifys when the AddAttachmentCell was selected
Default Implementation
Declaration
Swift
func attachmentManager(_ manager: AttachmentManager, didSelectAddAttachmentAt index: Int)
Parameters
manager
The AttachmentManager
attachments
The index of the AddAttachmentCell