static JComponent filePathInputWithBrowseButton(JTextField tf, O... _) { ret centerAndEastWithMargin(tf, jbutton("Browse...", r { JFileChooser fileChooser = new JFileChooser(getTextTrim(tf)); if (fileChooser.showOpenDialog(tf) == JFileChooser.APPROVE_OPTION) { tf.setText(fileChooser.getSelectedFile().getAbsolutePath()); callF(optPar onChoose(_)); } })); }