use of org.parosproxy.paros.view.OptionsDialog in project zaproxy by zaproxy.
the class MenuToolsControl method options.
// ZAP: added ability to select panel
public void options(String panel) {
OptionsDialog dialog = view.getOptionsDialog(Constant.messages.getString("options.dialog.title"));
dialog.initParam(model.getOptionsParam());
int result = dialog.showDialog(false, panel);
if (result == JOptionPane.OK_OPTION) {
try {
model.getOptionsParam().getConfig().save();
} catch (ConfigurationException e) {
logger.error(e.getMessage(), e);
view.showWarningDialog(Constant.messages.getString("menu.tools.options.errorSavingOptions"));
return;
}
// ZAP: Notify all OptionsChangedListener.
control.getExtensionLoader().optionsChangedAllPlugin(model.getOptionsParam());
view.getMainFrame().applyViewOptions();
control.getProxy().stopServer();
control.getProxy().startServer();
}
}
Aggregations