title: Why am I unable to programmatically close a Dialog on JavaFX?
body: <p>This sample of code shows but doesn't close a javafx.scene.control.Dialog on JavaFx:</p>
  
  <pre><code>Dialog&lt;Void&gt; dialog = new Dialog&lt;Void&gt;();
  dialog.show();
  dialog.close();
  </code></pre>
  
  <p>or</p>
  
  <pre><code>Dialog&lt;Void&gt; dialog = new Dialog&lt;Void&gt;();
  dialog.show();
  dialog.hide();
  </code></pre>
  
  <p>Why?</p>