_publisherOptionsModel.remove((PublisherOption) _tablePublisherOptions.getTable().getSelection()[0].getData());
}
}
protected void handleAddPublisherOption() {
InputDialog dialog = new InputDialog(getSite().getShell(), "Add publisher option", "Please specify the publiser option name:", null, new IInputValidator() {
public String isValid(String newText) {
if (newText == null || newText.trim().equals("")) {
return "";
}
if (WGADesignConfigurationModel.DIRECT_MODIFIABLE_PUBLISHER_OPTIONS.contains(newText.trim())) {
return "Please use the corresponding control in the design editor to configure this option.";
}
return null;
}
});
dialog.open();
String optionName = dialog.getValue();
if (optionName != null && !optionName.trim().equals("")) {
PublisherOption option = new PublisherOption();
option.setName(optionName);
option.setValue("<value>");
_publisherOptionsModel.add(option);