title: Subviews on UICollectionViewCell jumped between cells
body: <p>I have an <code>UICollectionView</code> with multiple sections and multiple types of custom cells on it.</p>
  
  <p>But instead of showing the same subviews on each cell of the same type, every time I scroll the section off the screen and back on, only part of the custom cell show the subviews on them.</p>
  
  <p>Please check the screen shots below:</p>
  
  <p><a href="https://i.stack.imgur.com/t4Gw9.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/t4Gw9.jpg" alt="enter image description here"></a> 
  <a href="https://i.stack.imgur.com/uGWuu.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/uGWuu.jpg" alt="enter image description here"></a></p>
  
  <p>Why is that?</p>
  
  <p>I have registered all kinds of cell in <code>viewDidLoad</code>:</p>
  
  <pre><code>[self registerClass:[UICollectionViewCell class] forCellWithReuseIdentifier:normalCellID];
  [self registerClass:[BLMineSectionCollectionViewCell class] forCellWithReuseIdentifier:sectionCellID];
  [self registerClass:[BLMineOrderCollectionViewCell class] forCellWithReuseIdentifier:orderCellID];
  </code></pre>
  
  <p>And in <code>cellForItemAtIndexPath</code> I did:</p>
  
  <pre><code>if (indexPath.section == 0 ||
      indexPath.section == 2 ||
      indexPath.section == 4 ||
      indexPath.section == 5)
  {
      BLMineSectionCollectionViewCell *sectionCell = [collectionView dequeueReusableCellWithReuseIdentifier:sectionCellID forIndexPath:indexPath];
      return sectionCell;
  }
  else if (indexPath.section == 1)
  {
      BLMineOrderCollectionViewCell *orderCell = [collectionView dequeueReusableCellWithReuseIdentifier:orderCellID forIndexPath:indexPath];
      UIColor *color = nil;
      switch (indexPath.item)
      {
          case 0:
              color = [UIColor redColor];
              break;
          case 1:
              color = [UIColor greenColor];
              break;
          case 2:
              color = [UIColor purpleColor];
              break;
          default:
              color = nil;
              break;
      }
      orderCell.iconImageView.backgroundColor = color;
      orderCell.textLabel.backgroundColor = color;
      return orderCell;
  }
  else
  {
      UIColor *color = nil;
      color = [UIColor blueColor];
      UICollectionViewCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:normalCellID forIndexPath:indexPath];
      cell.contentView.backgroundColor = color;
      return cell;
  }
  </code></pre>
  
  <p>Please point out my mistakes, thanks!</p>