use of org.zaproxy.zap.view.widgets.ContextSelectComboBox in project zaproxy by zaproxy.
the class AbstractContextSelectToolbarStatusPanel method getContextSelectComboBox.
/**
* Gets the Context select combo box.
*
* @return the context select combo box
*/
protected ContextSelectComboBox getContextSelectComboBox() {
if (contextSelectBox == null) {
contextSelectBox = new ContextSelectComboBox();
contextSelectBox.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
contextSelected((Context) contextSelectBox.getSelectedItem());
}
});
}
return contextSelectBox;
}
use of org.zaproxy.zap.view.widgets.ContextSelectComboBox in project zaproxy by zaproxy.
the class StandardFieldsDialog method addContextSelectField.
public void addContextSelectField(int tabIndex, String fieldLabel, Context selectedContext) {
if (!isTabbed()) {
throw new IllegalArgumentException("Not initialised as a tabbed dialog - must use method without tab parameters");
}
if (tabIndex < 0 || tabIndex >= this.tabPanels.size()) {
throw new IllegalArgumentException("Invalid tab index: " + tabIndex);
}
ContextSelectComboBox field = new ContextSelectComboBox();
if (selectedContext != null) {
field.setSelectedItem(selectedContext);
}
this.addField(this.tabPanels.get(tabIndex), this.tabOffsets.get(tabIndex), fieldLabel, field, field, 0.0D);
incTabOffset(tabIndex);
}
use of org.zaproxy.zap.view.widgets.ContextSelectComboBox in project zaproxy by zaproxy.
the class StandardFieldsDialog method addContextSelectField.
public void addContextSelectField(String fieldLabel, Context selectedContext) {
if (isTabbed()) {
throw new IllegalArgumentException("Initialised as a tabbed dialog - must use method with tab parameters");
}
ContextSelectComboBox field = new ContextSelectComboBox();
if (selectedContext != null) {
field.setSelectedItem(selectedContext);
}
this.addField(fieldLabel, field, field, 0.0D);
}
Aggregations