class CopyDataToOtherColumnUI extends javax.swing.JPanel implements AttributeColumnsManipulatorUI {

    CopyDataToOtherColumn manipulator;
    Column[] columns;
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JComboBox columnsComboBox;
    private javax.swing.JLabel descriptionLabel;
    private javax.swing.JLabel sourceColumnLabel;
    // End of variables declaration//GEN-END:variables

    /**
     * Creates new form CopyDataToOtherColumnUI
     */
    public CopyDataToOtherColumnUI() {
        initComponents();
    }

    @Override
    public void setup(AttributeColumnsManipulator m, GraphModel graphModel, Table table, Column column,
                      DialogControls dialogControls) {
        this.manipulator = (CopyDataToOtherColumn) m;

        sourceColumnLabel.setText(NbBundle
            .getMessage(CopyDataToOtherColumnUI.class, "CopyDataToOtherColumnUI.sourceColumnLabel.text",
                column.getTitle()));

        AttributeColumnsController ac = Lookup.getDefault().lookup(AttributeColumnsController.class);

        ArrayList<Column> availableColumns = new ArrayList<>();

        for (Column c : table) {
            if (ac.canChangeColumnData(c) && c != column) {
                availableColumns.add(c);
                columnsComboBox.addItem(c.getTitle());
            }
        }

        columns = availableColumns.toArray(new Column[0]);
    }

    @Override
    public void unSetup() {
        if (columnsComboBox.getSelectedIndex() != -1) {
            manipulator.setTargetColumn(columns[columnsComboBox.getSelectedIndex()]);
        } else {
            manipulator.setTargetColumn(null);
        }
    }

    @Override
    public String getDisplayName() {
        return manipulator.getName();
    }

    @Override
    public JPanel getSettingsPanel() {
        return this;
    }

    @Override
    public boolean isModal() {
        return true;
    }

    /**
     * This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this method is always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {<FILL_FUNCTION_BODY>}// </editor-fold>//GEN-END:initComponents
}


        descriptionLabel = new javax.swing.JLabel();
        columnsComboBox = new javax.swing.JComboBox();
        sourceColumnLabel = new javax.swing.JLabel();

        descriptionLabel.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        descriptionLabel.setText(org.openide.util.NbBundle
            .getMessage(CopyDataToOtherColumnUI.class, "CopyDataToOtherColumnUI.descriptionLabel.text")); // NOI18N

        sourceColumnLabel.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        sourceColumnLabel.setText(null);

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
        this.setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                .addGroup(layout.createSequentialGroup()
                    .addContainerGap()
                    .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addComponent(descriptionLabel, javax.swing.GroupLayout.DEFAULT_SIZE,
                            javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addComponent(columnsComboBox, 0, 192, Short.MAX_VALUE)
                        .addComponent(sourceColumnLabel, javax.swing.GroupLayout.DEFAULT_SIZE, 192, Short.MAX_VALUE))
                    .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                    .addContainerGap()
                    .addComponent(sourceColumnLabel)
                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED,
                        javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(descriptionLabel)
                    .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                    .addComponent(columnsComboBox, javax.swing.GroupLayout.PREFERRED_SIZE,
                        javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addContainerGap())
        );
    
<methods>public void <init>() ,public void <init>(java.awt.LayoutManager) ,public void <init>(boolean) ,public void <init>(java.awt.LayoutManager, boolean) ,public javax.accessibility.AccessibleContext getAccessibleContext() ,public javax.swing.plaf.PanelUI getUI() ,public java.lang.String getUIClassID() ,public void setUI(javax.swing.plaf.PanelUI) ,public void updateUI() <variables>private static final java.lang.String uiClassID