/** * Show dialog. * * @param frameComp the frame comp * @param locationComp the location comp * @param title the title * @param initialValue the initial value * @return the string */ public static String showDialog( Component frameComp, Component locationComp, String title, String initialValue) { Frame frame = JOptionPane.getFrameForComponent(frameComp); dialog = new EditDialog(frame, locationComp, title, initialValue); dialog.setVisible(true); return value; }