title: UICollectionView scrollToItemAtIndexPath cell disappears when half hidden
body: <p>I'm trying to automatically move cells in my <code>UICollectionView</code>. The code to move it:</p>
  
  <pre><code>- (void)scroll {
      row += 2;
      [UIView animateWithDuration:1.f
                            delay:0.f
                          options:UIViewAnimationOptionAllowUserInteraction
                       animations:^{
                           [_collectionView scrollToItemAtIndexPath:[NSIndexPath indexPathForRow:row inSection:0] atScrollPosition:UICollectionViewScrollPositionNone animated:NO];
                       }
                        completion:^(BOOL finished) {
      }];
  }
  </code></pre>
  
  <p>My cells are organized horizontally in 2 rows pattern:</p>
  
  <pre><code>|cell||cell||cell|-&gt;etc
  |cell||cell||cell|-&gt;etc
  </code></pre>
  
  <p>The problem is that when scroll moves to the next cell, so whole collectionView moves, previous cell disappears. It happens exactly when half of the previous cell is not visible on the screen. Why can it happen? Any idea how to fix the issue?</p>
  
  <p>It looks like: (~ means screen)</p>
  
  <pre><code>step 1:
  ~|cell||cell||cell|~
  ~|cell||cell||cell|~
  
  step 2:
  ~ell||cell||cell||c~
  ~ell||cell||cell||c~
  
  step 3:
  ~ll||cell||cell||ce~
  ~ll||cell||cell||ce~
  
  step 4:
  ~  |cell||cell||cel~ --&gt; here first cell disappears even though
  ~  |cell||cell||cel~ --&gt; there is enough space for it
  </code></pre>
  
  <p>What is more, the delegate: <code>collectionView:didEndDisplayingCell:forItemAtIndexPath:</code> gets called when the cell is half visible (so exactly between step 3&amp;4)</p>