title: How can I fix the "UIPopoverController is deprecated" warning?
body: <p>I am using this code:</p>
  
  <pre><code>mediaLibraryPopover = [[UIPopoverController alloc] 
                          initWithContentViewController:avc];
  [self.mediaLibraryPopover presentPopoverFromRect:[theButton bounds] 
                            inView:theButton 
                            permittedArrowDirections:UIPopoverArrowDirectionAny 
                            animated:YES];
  </code></pre>
  
  <p>And I am getting this warning in Xcode 7:</p>
  
  <blockquote>
    <p>UIPopoverController is deprecated, first deprecated in iOS 9.0 - UIPopoverController is deprecated. Popovers are now implemented as UIViewController presentations. Use a modal presentation style of UIModalPresentationPopover and UIPopoverPresentationController.</p>
  </blockquote>