title: How do I dismiss a sheet with the escape key?
body: <p>My app displays an <code>NSWindow</code> as a sheet. The <code>NSWindow</code> has various controls for settings properties of an object (an NSTextfield, a <code>NSDatepicker</code> etc) and two <code>NSButton</code>'s, 'Add' and 'Cancel' which are used to confirm or cancel the action.</p>
  
  <p>I have set the key equivalent of the 'Add' button to <code>enter</code> and the key equivalent of <code>Cancel</code> to <code>escape</code>. This does not have the desired affect. I think this is due to the other controls handling the keypress events.</p>
  
  <p>How do I configure my sheet so that the buttons behave as described?</p>