Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SWIFT

deselect all cell in collectionview

extension UICollectionView {

    func deselectAllItems(animated: Bool) {
        guard let selectedItems = indexPathsForSelectedItems else { return }
        for indexPath in selectedItems { deselectItem(at: indexPath, animated: animated) }
    }
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #deselect #cell #collectionview
ADD COMMENT
Topic
Name
6+9 =