                     self.setSelected(false, for: indexPath)
                 }
             })
-            print(selectedIndices)
         }
     }
 


internal class DragSelectionManager: NSObject {
    private weak var collectionView: UICollectionView!
    private var selectedIndices = [IndexPath]()
    private let nilPath = IndexPath(item: -1, section: -1)

    ///Initializes a `DragSelectionManager` with the provided `UICollectionView`.

     `true` for selected, `false` for deselected.
     */
    @discardableResult internal func toggleSelected(indexPath: IndexPath) -> Bool {
        if collectionView.indexPathsForSelectedItems?.contains(indexPath) == true { //is selected, attempt remove selection
            if collectionView.delegate?.collectionView?(collectionView, shouldDeselectItemAt: indexPath) == true {
                collectionView.deselectItem(at: indexPath, animated: true)
                collectionView.delegate?.collectionView?(collectionView, didDeselectItemAt: indexPath)
                return false
            } else { return true } //deselection disallowed, keep selected
        } else { //is unselected, attempt selection
            if collectionView.delegate?.collectionView?(collectionView, shouldSelectItemAt: indexPath) == true &&
            (maxSelectionCount == nil || collectionView.indexPathsForSelectedItems?.count ?? 0 < maxSelectionCount!) {
                collectionView.selectItem(at: indexPath, animated: true, scrollPosition: [])
                collectionView.delegate?.collectionView?(collectionView, didSelectItemAt: indexPath)
                return true
