private void closeDialog()
void closeDialog()
  private void closeDialog()  {    Window owner = SwingUtilities.windowForComponent(filechooser);    if (owner instanceof JDialog)      ((JDialog) owner).dispose();  }