Search in sources :

Example 1 with AddColumnUI

use of org.gephi.desktop.datalab.general.actions.AddColumnUI in project gephi by gephi.

the class DataTableTopComponent method showAddColumnUI.

private void showAddColumnUI(AddColumnUI.Mode mode) {
    JButton okButton = new JButton(NbBundle.getMessage(DataTableTopComponent.class, "DataTableTopComponent.dialogs.okButton.text"));
    AddColumnUI addColumnUI = new AddColumnUI();
    addColumnUI.setup(mode);
    addColumnUI.setOkButton(okButton);
    DialogDescriptor dd = new DialogDescriptor(AddColumnUI.createValidationPanel(addColumnUI), addColumnUI.getDisplayName());
    dd.setOptions(new Object[] { okButton, DialogDescriptor.CANCEL_OPTION });
    if (DialogDisplayer.getDefault().notify(dd).equals(okButton)) {
        addColumnUI.execute();
    }
    addColumnUI.unSetup();
}
Also used : AddColumnUI(org.gephi.desktop.datalab.general.actions.AddColumnUI) JButton(javax.swing.JButton) DialogDescriptor(org.openide.DialogDescriptor)

Aggregations

JButton (javax.swing.JButton)1 AddColumnUI (org.gephi.desktop.datalab.general.actions.AddColumnUI)1 DialogDescriptor (org.openide.DialogDescriptor)1