Search in sources :

Example 1 with ParamAddinMagic

use of org.zaproxy.zap.extension.httppanel.view.paramtable.addins.ParamAddinMagic in project zaproxy by zaproxy.

the class HttpPanelParamTableView method initAddins.

private void initAddins() {
    // Get all addins
    addins = new LinkedList<>();
    addins.add(new ParamAddinMagic());
    addins.add(new ParamAddinUrlencode());
    comboBoxAddIns = new JComboBox<>();
    comboBoxAddIns.addItem(ADD_INS);
    for (ParamAddinInterface addin : addins) {
        comboBoxAddIns.addItem(addin);
    }
    comboBoxAddIns.addActionListener(new ComboBoxAddinsActionListener());
    table.getColumnModel().getColumn(0).setCellEditor(new DefaultCellEditor(getComboBoxTypes()));
    table.setAutoResizeMode(JTable.AUTO_RESIZE_NEXT_COLUMN);
    if (table.getColumnCount() != 4) {
        return;
    }
    table.getColumnModel().getColumn(3).setCellEditor(new DefaultCellEditor(comboBoxAddIns));
    table.getColumnModel().getColumn(3).setCellRenderer(new ComboBoxCellRenderer(comboBoxAddIns));
}
Also used : ParamAddinInterface(org.zaproxy.zap.extension.httppanel.view.paramtable.addins.ParamAddinInterface) ParamAddinMagic(org.zaproxy.zap.extension.httppanel.view.paramtable.addins.ParamAddinMagic) ParamAddinUrlencode(org.zaproxy.zap.extension.httppanel.view.paramtable.addins.ParamAddinUrlencode) DefaultCellEditor(javax.swing.DefaultCellEditor)

Aggregations

DefaultCellEditor (javax.swing.DefaultCellEditor)1 ParamAddinInterface (org.zaproxy.zap.extension.httppanel.view.paramtable.addins.ParamAddinInterface)1 ParamAddinMagic (org.zaproxy.zap.extension.httppanel.view.paramtable.addins.ParamAddinMagic)1 ParamAddinUrlencode (org.zaproxy.zap.extension.httppanel.view.paramtable.addins.ParamAddinUrlencode)1