public static void openAbout(Frame frame, String product, String version) { AboutDialog aboutDialog = new AboutDialog(frame, true, product, version); Dimension frameSize = frame.getSize(); Dimension aboutSize = aboutDialog.getSize(); int x = frame.getLocation().x + (frameSize.width - aboutSize.width) / 2; int y = frame.getLocation().y + (frameSize.height - aboutSize.height) / 2; if (x < 0) x = 0; if (y < 0) y = 0; aboutDialog.setLocation(x, y); aboutDialog.setVisible(true); }