title: How to detect tapping on the gray (dimmed) background in UISearchDisplayController
body: <p>I am working on a iOS project where I want to implement a search functionality. I'm using <code>UISearchBar</code> and <code>UISearchDisplayController</code> and I would like to make <code>UISearchBar</code> implicitly hidden. When user taps on the <code>UIBarButtonItem</code>, the search bar will appear and "becomeFirstResponder", whereas when user clicks on the <code>Cancel</code> button in the search bar, it should disappear. </p>
  
  <p>The appearing is working correctly, but I have a problem with disappearing. I managed to hide the search bar when user taps on the <code>Cancel</code> button (<code>searchBarCancelButtonClicked</code> method), but I'm unable to hide the search bar when the grey (dimmed) background in <code>UISearchDisplayController</code> is tapped. As far as I know, there is no method to detect this event, so it is necessary to apply some hack. Do you know any, or what is the best way to detect tapping on the gray background?</p>