Trait objc2_ui_kit::UICollectionViewDelegate
source ยท pub unsafe trait UICollectionViewDelegate: UIScrollViewDelegate + IsMainThreadOnly {
Show 40 methods
// Provided methods
unsafe fn collectionView_shouldHighlightItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
) -> bool
where Self: Sized + Message { ... }
unsafe fn collectionView_didHighlightItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
)
where Self: Sized + Message { ... }
unsafe fn collectionView_didUnhighlightItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
)
where Self: Sized + Message { ... }
unsafe fn collectionView_shouldSelectItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
) -> bool
where Self: Sized + Message { ... }
unsafe fn collectionView_shouldDeselectItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
) -> bool
where Self: Sized + Message { ... }
unsafe fn collectionView_didSelectItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
)
where Self: Sized + Message { ... }
unsafe fn collectionView_didDeselectItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
)
where Self: Sized + Message { ... }
unsafe fn collectionView_canPerformPrimaryActionForItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
) -> bool
where Self: Sized + Message { ... }
unsafe fn collectionView_performPrimaryActionForItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
)
where Self: Sized + Message { ... }
unsafe fn collectionView_willDisplayCell_forItemAtIndexPath(
&self,
collection_view: &UICollectionView,
cell: &UICollectionViewCell,
index_path: &NSIndexPath
)
where Self: Sized + Message { ... }
unsafe fn collectionView_willDisplaySupplementaryView_forElementKind_atIndexPath(
&self,
collection_view: &UICollectionView,
view: &UICollectionReusableView,
element_kind: &NSString,
index_path: &NSIndexPath
)
where Self: Sized + Message { ... }
unsafe fn collectionView_didEndDisplayingCell_forItemAtIndexPath(
&self,
collection_view: &UICollectionView,
cell: &UICollectionViewCell,
index_path: &NSIndexPath
)
where Self: Sized + Message { ... }
unsafe fn collectionView_didEndDisplayingSupplementaryView_forElementOfKind_atIndexPath(
&self,
collection_view: &UICollectionView,
view: &UICollectionReusableView,
element_kind: &NSString,
index_path: &NSIndexPath
)
where Self: Sized + Message { ... }
unsafe fn collectionView_shouldShowMenuForItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
) -> bool
where Self: Sized + Message { ... }
unsafe fn collectionView_canPerformAction_forItemAtIndexPath_withSender(
&self,
collection_view: &UICollectionView,
action: Sel,
index_path: &NSIndexPath,
sender: Option<&AnyObject>
) -> bool
where Self: Sized + Message { ... }
unsafe fn collectionView_performAction_forItemAtIndexPath_withSender(
&self,
collection_view: &UICollectionView,
action: Sel,
index_path: &NSIndexPath,
sender: Option<&AnyObject>
)
where Self: Sized + Message { ... }
unsafe fn collectionView_transitionLayoutForOldLayout_newLayout(
&self,
collection_view: &UICollectionView,
from_layout: &UICollectionViewLayout,
to_layout: &UICollectionViewLayout
) -> Retained<UICollectionViewTransitionLayout>
where Self: Sized + Message { ... }
unsafe fn collectionView_canFocusItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
) -> bool
where Self: Sized + Message { ... }
unsafe fn collectionView_shouldUpdateFocusInContext(
&self,
collection_view: &UICollectionView,
context: &UICollectionViewFocusUpdateContext
) -> bool
where Self: Sized + Message { ... }
unsafe fn collectionView_didUpdateFocusInContext_withAnimationCoordinator(
&self,
collection_view: &UICollectionView,
context: &UICollectionViewFocusUpdateContext,
coordinator: &UIFocusAnimationCoordinator
)
where Self: Sized + Message { ... }
unsafe fn indexPathForPreferredFocusedViewInCollectionView(
&self,
collection_view: &UICollectionView
) -> Option<Retained<NSIndexPath>>
where Self: Sized + Message { ... }
unsafe fn collectionView_selectionFollowsFocusForItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
) -> bool
where Self: Sized + Message { ... }
unsafe fn collectionView_targetIndexPathForMoveOfItemFromOriginalIndexPath_atCurrentIndexPath_toProposedIndexPath(
&self,
collection_view: &UICollectionView,
original_index_path: &NSIndexPath,
current_index_path: &NSIndexPath,
proposed_index_path: &NSIndexPath
) -> Retained<NSIndexPath>
where Self: Sized + Message { ... }
unsafe fn collectionView_targetIndexPathForMoveFromItemAtIndexPath_toProposedIndexPath(
&self,
collection_view: &UICollectionView,
current_index_path: &NSIndexPath,
proposed_index_path: &NSIndexPath
) -> Retained<NSIndexPath>
where Self: Sized + Message { ... }
unsafe fn collectionView_targetContentOffsetForProposedContentOffset(
&self,
collection_view: &UICollectionView,
proposed_content_offset: CGPoint
) -> CGPoint
where Self: Sized + Message { ... }
unsafe fn collectionView_canEditItemAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
) -> bool
where Self: Sized + Message { ... }
unsafe fn collectionView_shouldSpringLoadItemAtIndexPath_withContext(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath,
context: &ProtocolObject<dyn UISpringLoadedInteractionContext>
) -> bool
where Self: Sized + Message { ... }
unsafe fn collectionView_shouldBeginMultipleSelectionInteractionAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
) -> bool
where Self: Sized + Message { ... }
unsafe fn collectionView_didBeginMultipleSelectionInteractionAtIndexPath(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath
)
where Self: Sized + Message { ... }
unsafe fn collectionViewDidEndMultipleSelectionInteraction(
&self,
collection_view: &UICollectionView
)
where Self: Sized + Message { ... }
unsafe fn collectionView_contextMenuConfigurationForItemsAtIndexPaths_point(
&self,
collection_view: &UICollectionView,
index_paths: &NSArray<NSIndexPath>,
point: CGPoint
) -> Option<Retained<UIContextMenuConfiguration>>
where Self: Sized + Message { ... }
unsafe fn collectionView_contextMenuConfiguration_highlightPreviewForItemAtIndexPath(
&self,
collection_view: &UICollectionView,
configuration: &UIContextMenuConfiguration,
index_path: &NSIndexPath
) -> Option<Retained<UITargetedPreview>>
where Self: Sized + Message { ... }
unsafe fn collectionView_contextMenuConfiguration_dismissalPreviewForItemAtIndexPath(
&self,
collection_view: &UICollectionView,
configuration: &UIContextMenuConfiguration,
index_path: &NSIndexPath
) -> Option<Retained<UITargetedPreview>>
where Self: Sized + Message { ... }
unsafe fn collectionView_willPerformPreviewActionForMenuWithConfiguration_animator(
&self,
collection_view: &UICollectionView,
configuration: &UIContextMenuConfiguration,
animator: &ProtocolObject<dyn UIContextMenuInteractionCommitAnimating>
)
where Self: Sized + Message { ... }
unsafe fn collectionView_willDisplayContextMenuWithConfiguration_animator(
&self,
collection_view: &UICollectionView,
configuration: &UIContextMenuConfiguration,
animator: Option<&ProtocolObject<dyn UIContextMenuInteractionAnimating>>
)
where Self: Sized + Message { ... }
unsafe fn collectionView_willEndContextMenuInteractionWithConfiguration_animator(
&self,
collection_view: &UICollectionView,
configuration: &UIContextMenuConfiguration,
animator: Option<&ProtocolObject<dyn UIContextMenuInteractionAnimating>>
)
where Self: Sized + Message { ... }
unsafe fn collectionView_sceneActivationConfigurationForItemAtIndexPath_point(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath,
point: CGPoint
) -> Option<Retained<UIWindowSceneActivationConfiguration>>
where Self: Sized + Message { ... }
unsafe fn collectionView_contextMenuConfigurationForItemAtIndexPath_point(
&self,
collection_view: &UICollectionView,
index_path: &NSIndexPath,
point: CGPoint
) -> Option<Retained<UIContextMenuConfiguration>>
where Self: Sized + Message { ... }
unsafe fn collectionView_previewForHighlightingContextMenuWithConfiguration(
&self,
collection_view: &UICollectionView,
configuration: &UIContextMenuConfiguration
) -> Option<Retained<UITargetedPreview>>
where Self: Sized + Message { ... }
unsafe fn collectionView_previewForDismissingContextMenuWithConfiguration(
&self,
collection_view: &UICollectionView,
configuration: &UIContextMenuConfiguration
) -> Option<Retained<UITargetedPreview>>
where Self: Sized + Message { ... }
}Available on crate features
UICollectionView and UIScrollView only.Provided Methodsยง
unsafe fn collectionView_shouldHighlightItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath ) -> bool
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_didHighlightItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath )
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_didUnhighlightItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath )
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_shouldSelectItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath ) -> bool
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_shouldDeselectItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath ) -> bool
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_didSelectItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath )
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_didDeselectItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath )
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_canPerformPrimaryActionForItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath ) -> bool
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_performPrimaryActionForItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath )
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_willDisplayCell_forItemAtIndexPath( &self, collection_view: &UICollectionView, cell: &UICollectionViewCell, index_path: &NSIndexPath )
Available on crate features
UICollectionViewCell and UIResponder and UIView only.unsafe fn collectionView_willDisplaySupplementaryView_forElementKind_atIndexPath( &self, collection_view: &UICollectionView, view: &UICollectionReusableView, element_kind: &NSString, index_path: &NSIndexPath )
Available on crate features
UICollectionViewCell and UIResponder and UIView only.unsafe fn collectionView_didEndDisplayingCell_forItemAtIndexPath( &self, collection_view: &UICollectionView, cell: &UICollectionViewCell, index_path: &NSIndexPath )
Available on crate features
UICollectionViewCell and UIResponder and UIView only.unsafe fn collectionView_didEndDisplayingSupplementaryView_forElementOfKind_atIndexPath( &self, collection_view: &UICollectionView, view: &UICollectionReusableView, element_kind: &NSString, index_path: &NSIndexPath )
Available on crate features
UICollectionViewCell and UIResponder and UIView only.unsafe fn collectionView_shouldShowMenuForItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath ) -> bool
๐Deprecated
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_canPerformAction_forItemAtIndexPath_withSender( &self, collection_view: &UICollectionView, action: Sel, index_path: &NSIndexPath, sender: Option<&AnyObject> ) -> bool
๐Deprecated
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_performAction_forItemAtIndexPath_withSender( &self, collection_view: &UICollectionView, action: Sel, index_path: &NSIndexPath, sender: Option<&AnyObject> )
๐Deprecated
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_transitionLayoutForOldLayout_newLayout( &self, collection_view: &UICollectionView, from_layout: &UICollectionViewLayout, to_layout: &UICollectionViewLayout ) -> Retained<UICollectionViewTransitionLayout>
Available on crate features
UICollectionViewLayout and UICollectionViewTransitionLayout and UIResponder and UIView only.unsafe fn collectionView_canFocusItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath ) -> bool
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_shouldUpdateFocusInContext( &self, collection_view: &UICollectionView, context: &UICollectionViewFocusUpdateContext ) -> bool
Available on crate features
UIFocus and UIResponder and UIView only.unsafe fn collectionView_didUpdateFocusInContext_withAnimationCoordinator( &self, collection_view: &UICollectionView, context: &UICollectionViewFocusUpdateContext, coordinator: &UIFocusAnimationCoordinator )
Available on crate features
UIFocus and UIFocusAnimationCoordinator and UIResponder and UIView only.unsafe fn indexPathForPreferredFocusedViewInCollectionView( &self, collection_view: &UICollectionView ) -> Option<Retained<NSIndexPath>>
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_selectionFollowsFocusForItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath ) -> bool
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_targetIndexPathForMoveOfItemFromOriginalIndexPath_atCurrentIndexPath_toProposedIndexPath( &self, collection_view: &UICollectionView, original_index_path: &NSIndexPath, current_index_path: &NSIndexPath, proposed_index_path: &NSIndexPath ) -> Retained<NSIndexPath>
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_targetIndexPathForMoveFromItemAtIndexPath_toProposedIndexPath( &self, collection_view: &UICollectionView, current_index_path: &NSIndexPath, proposed_index_path: &NSIndexPath ) -> Retained<NSIndexPath>
๐Deprecated
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_targetContentOffsetForProposedContentOffset( &self, collection_view: &UICollectionView, proposed_content_offset: CGPoint ) -> CGPoint
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_canEditItemAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath ) -> bool
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_shouldSpringLoadItemAtIndexPath_withContext( &self, collection_view: &UICollectionView, index_path: &NSIndexPath, context: &ProtocolObject<dyn UISpringLoadedInteractionContext> ) -> bool
Available on crate features
UIResponder and UISpringLoadedInteraction and UIView only.unsafe fn collectionView_shouldBeginMultipleSelectionInteractionAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath ) -> bool
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_didBeginMultipleSelectionInteractionAtIndexPath( &self, collection_view: &UICollectionView, index_path: &NSIndexPath )
Available on crate features
UIResponder and UIView only.unsafe fn collectionViewDidEndMultipleSelectionInteraction( &self, collection_view: &UICollectionView )
Available on crate features
UIResponder and UIView only.unsafe fn collectionView_contextMenuConfigurationForItemsAtIndexPaths_point( &self, collection_view: &UICollectionView, index_paths: &NSArray<NSIndexPath>, point: CGPoint ) -> Option<Retained<UIContextMenuConfiguration>>
Available on crate features
UIContextMenuConfiguration and UIResponder and UIView only.unsafe fn collectionView_contextMenuConfiguration_highlightPreviewForItemAtIndexPath( &self, collection_view: &UICollectionView, configuration: &UIContextMenuConfiguration, index_path: &NSIndexPath ) -> Option<Retained<UITargetedPreview>>
Available on crate features
UIContextMenuConfiguration and UIResponder and UITargetedPreview and UIView only.unsafe fn collectionView_contextMenuConfiguration_dismissalPreviewForItemAtIndexPath( &self, collection_view: &UICollectionView, configuration: &UIContextMenuConfiguration, index_path: &NSIndexPath ) -> Option<Retained<UITargetedPreview>>
Available on crate features
UIContextMenuConfiguration and UIResponder and UITargetedPreview and UIView only.unsafe fn collectionView_willPerformPreviewActionForMenuWithConfiguration_animator( &self, collection_view: &UICollectionView, configuration: &UIContextMenuConfiguration, animator: &ProtocolObject<dyn UIContextMenuInteractionCommitAnimating> )
Available on crate features
UIContextMenuConfiguration and UIContextMenuInteraction and UIResponder and UIView only.unsafe fn collectionView_willDisplayContextMenuWithConfiguration_animator( &self, collection_view: &UICollectionView, configuration: &UIContextMenuConfiguration, animator: Option<&ProtocolObject<dyn UIContextMenuInteractionAnimating>> )
Available on crate features
UIContextMenuConfiguration and UIContextMenuInteraction and UIResponder and UIView only.unsafe fn collectionView_willEndContextMenuInteractionWithConfiguration_animator( &self, collection_view: &UICollectionView, configuration: &UIContextMenuConfiguration, animator: Option<&ProtocolObject<dyn UIContextMenuInteractionAnimating>> )
Available on crate features
UIContextMenuConfiguration and UIContextMenuInteraction and UIResponder and UIView only.unsafe fn collectionView_sceneActivationConfigurationForItemAtIndexPath_point( &self, collection_view: &UICollectionView, index_path: &NSIndexPath, point: CGPoint ) -> Option<Retained<UIWindowSceneActivationConfiguration>>
Available on crate features
UIResponder and UIView and UIWindowSceneActivationConfiguration only.unsafe fn collectionView_contextMenuConfigurationForItemAtIndexPath_point( &self, collection_view: &UICollectionView, index_path: &NSIndexPath, point: CGPoint ) -> Option<Retained<UIContextMenuConfiguration>>
๐Deprecated
Available on crate features
UIContextMenuConfiguration and UIResponder and UIView only.unsafe fn collectionView_previewForHighlightingContextMenuWithConfiguration( &self, collection_view: &UICollectionView, configuration: &UIContextMenuConfiguration ) -> Option<Retained<UITargetedPreview>>
๐Deprecated
Available on crate features
UIContextMenuConfiguration and UIResponder and UITargetedPreview and UIView only.unsafe fn collectionView_previewForDismissingContextMenuWithConfiguration( &self, collection_view: &UICollectionView, configuration: &UIContextMenuConfiguration ) -> Option<Retained<UITargetedPreview>>
๐Deprecated
Available on crate features
UIContextMenuConfiguration and UIResponder and UITargetedPreview and UIView only.Trait Implementationsยง
sourceยงimpl ProtocolType for dyn UICollectionViewDelegate
impl ProtocolType for dyn UICollectionViewDelegate
impl<T> ImplementedBy<T> for dyn UICollectionViewDelegate
Implementations on Foreign Typesยง
impl<T> UICollectionViewDelegate for ProtocolObject<T>where
T: ?Sized + UICollectionViewDelegate,
Implementorsยง
impl UICollectionViewDelegate for UICollectionViewController
Available on crate features
UIResponder and UIViewController and UICollectionViewController only.