Kodeco Forums

Video Tutorial: Collection Views Part 6: Moving Cells

In this video tutorial, you'll learn how to move cells around collection views using drag and drop.


This is a companion discussion topic for the original entry at https://www.raywenderlich.com/2002-video-tutorial-collection-views-part-6-moving-cells

Hey Mic!

Loving the tutorials learning heaps!
I’ve been playing around with this for a few days and i cant figure this one & was wondering if you could shed some light on the situation

What i’m trying to achieve is being able to select and de-select a cell by tapping on it, so first tap selects the cell and second tap deselects, also trying to have it so only one cell can be selected at a time and as long as any one cell is selected it will be in ‘editing’ mode…

Selecting and highlighting the cell is fine but the didDeselectItemAtIndexPath method never gets called… I’ve even tried making a custom tap gesture and still no luck…

Any ideas?

Hey @bryce,

Glad you’re enjoying the tutorials, and thanks for the kind words.

It’s a little difficult to diagnose your issue without seeing your code, so I’ve attached a small sample project that I think achieves what you’ve mentioned, which you can then compare against your own implementation.

Hopefully this’ll help. :smiley:

CollectionViewSelection.zip (24.9 KB)