title: javafx.scene.control.Dialog<R> won't close on pressing "x"
body: <p>If I just create an empty class extending from <code>javafx.scene.control.Dialog&lt;R&gt;</code>, it won't close when I'm pressing the "x" button in the top right corner.</p>
  
  <p>How do I implement this behaviour? The API seems to tell me that I need to implement a close button. But in my case I don't want a close button, I just want to close the window with the x button or by pressing ESC. Is this possible?</p>