title: Drawing selected state on custom UITableViewCell
body: <p>I have a customer <code>UITableViewCell</code> whose whole display is drawn in<code>drawRect</code>.  When it draws it creates <code>CGLayers</code> so that it can reuse certain pieces when something is changed.  </p>
  
  <p>I have changed my <code>UITableViewCellSelectionStyle</code> to "None" because I don't want the default selected view to cover my drawing. </p>
  
  <p>My problem is that I call <code>setNeedsDisplay</code> in <code>setSelected:animated:</code> for my cell but by the time <code>drawRect</code> is called, <code>setSelected:animated:</code> has already been called again to deselect the cell.  In my table view controller <code>didSelectRowAtIndexPath</code>, I call <code>deselectRowAtIndexPath</code> as Apple advises.  </p>
  
  <p>EDIT - I have also tried called the setNeedsDisplay on my cell from my table view controller's <code>(NSIndexPath *)tableView:(UITableView *)tableView willSelectRowAtIndexPath:(NSIndexPath *)indexPath</code> but that didn't change anything.</p>
  
  <p>Any ideas?   Thanks.</p>