title: Play/Pause remote key for UICollectionViewCell in tvOS
body: <p>My requirement is to play movies from <code>UICollectionView</code> directly by pressing play/pause remote key when cell is focused.</p>
  
  <p>It is perfectly working if we go background(by pressing home button) and come to foreground (or) presenting <code>viewcontroller</code> and dismissing. But normal cases it is not working.</p>
  
  <p>Play/Pause is not working for custom <code>AVPlayer</code> also as I am not using <code>avplayer</code> controls (here also Play/pause works like above cases)</p>
  
  <p>Same code below</p>
  
  <p>I am returning <code>UICollectionViewCell</code> whenever <code>preferredFocusEnvironments</code> gets called</p>
  
  <pre><code>func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -&gt; UICollectionViewCell {
  
          let cell = collectionView.dequeueReusableCell(withReuseIdentifier:SuggestionsCollectionViewCell.reuseIdentifier, for: indexPath) as! SuggestionsCollectionViewCell
      let playPauseRecognizer = UITapGestureRecognizer(target: self, action: #selector(selectThisMagazineCell))
          playPauseRecognizer.allowedPressTypes = [NSNumber(value: UIPressType.playPause.rawValue)]
          playPauseRecognizer.numberOfTapsRequired = 1
          cell.addGestureRecognizer(playPauseRecognizer)
  return cell
  }
  </code></pre>
  
  <p>For <code>AVPLayerViewController</code> class I have code like below for play/pause</p>
  
  <pre><code>let playPauseRecognizer = UITapGestureRecognizer(target: self, action: #selector(playPauseMenuButtonPressed))
      playPauseRecognizer.allowedPressTypes = [NSNumber(value: UIPressType.playPause.rawValue)];
      self.view.addGestureRecognizer(playPauseRecognizer)
  </code></pre>