use of games.strategy.engine.data.properties.PropertiesUi in project triplea by triplea-game.
the class PropertiesSelector method showDialog.
private static Object showDialog(final JComponent parent, final String title, final List<IEditableProperty> properties, final Object... buttonOptions) {
final PropertiesUi panel = new PropertiesUi(properties, true);
final JScrollPane scroll = new JScrollPane(panel);
scroll.setBorder(null);
scroll.getViewport().setBorder(null);
final JOptionPane pane = new JOptionPane(scroll, JOptionPane.PLAIN_MESSAGE);
pane.setOptions(buttonOptions);
final JDialog window = pane.createDialog(JOptionPane.getFrameForComponent(parent), title);
window.setVisible(true);
return pane.getValue();
}
Aggregations