Instance Method

collectionView(_:previewForDismissingContextMenuWithConfiguration:)

Asks the delegate for the dismissal preview of the contextual menu.

Declaration

optional func collectionView(_ collectionView: UICollectionView, previewForDismissingContextMenuWithConfiguration configuration: UIContextMenuConfiguration) -> UITargetedPreview?

Parameters

collectionView

The collection view object requesting this information.

configuration

The configuration of the contextual menu displayed by this interaction.

Return Value

A targeted preview object describing the dismissal preview. The interaction animates the presented menu to the preview. Use this method to customize the dismissal animation.

See Also