use of org.zaproxy.zap.view.ZapMenuItem in project zaproxy by zaproxy.
the class MainMenuBar method getMenuToolsOptions.
private ZapMenuItem getMenuToolsOptions() {
if (menuToolsOptions == null) {
menuToolsOptions = new ZapMenuItem("menu.tools.options", View.getSingleton().getMenuShortcutKeyStroke(KeyEvent.VK_O, KeyEvent.ALT_DOWN_MASK, false));
menuToolsOptions.addActionListener(new java.awt.event.ActionListener() {
@Override
public void actionPerformed(java.awt.event.ActionEvent e) {
getMenuToolsControl().options();
}
});
}
return menuToolsOptions;
}
use of org.zaproxy.zap.view.ZapMenuItem in project zaproxy by zaproxy.
the class MainMenuBar method getMenuHelpSupport.
private ZapMenuItem getMenuHelpSupport() {
if (menuHelpSupport == null) {
menuHelpSupport = new ZapMenuItem("menu.help.zap.support");
menuHelpSupport.addActionListener(new java.awt.event.ActionListener() {
@Override
public void actionPerformed(java.awt.event.ActionEvent e) {
ZapSupportDialog zsd = new ZapSupportDialog(View.getSingleton().getMainFrame(), true);
zsd.setVisible(true);
}
});
}
return menuHelpSupport;
}
use of org.zaproxy.zap.view.ZapMenuItem in project zaproxy by zaproxy.
the class MainMenuBar method getMenuHelpAbout.
/**
* Gets the About menu
*
* @return the 'About' menu item.
*/
private ZapMenuItem getMenuHelpAbout() {
if (menuHelpAbout == null) {
menuHelpAbout = new ZapMenuItem("menu.help.about");
menuHelpAbout.addActionListener(new java.awt.event.ActionListener() {
@Override
public void actionPerformed(java.awt.event.ActionEvent e) {
AboutDialog dialog = new AboutDialog(View.getSingleton().getMainFrame(), true);
dialog.setVisible(true);
}
});
}
return menuHelpAbout;
}
use of org.zaproxy.zap.view.ZapMenuItem in project zaproxy by zaproxy.
the class View method registerMenu.
private void registerMenu(ExtensionKeyboard extKey, final AbstractPanel ap) {
ZapMenuItem tabMenu = new ZapMenuItem(ap.getClass().getName(), Constant.messages.getString("menu.view.tab", ap.getName()), ap.getDefaultAccelerator());
tabMenu.setMnemonic(ap.getMnemonic());
if (ap.getIcon() != null) {
tabMenu.setIcon(DisplayUtils.getScaledIcon(ap.getIcon()));
}
tabMenu.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
getWorkbench().showPanel(ap);
}
});
menuShowTabs.add(tabMenu);
if (extKey != null) {
extKey.registerMenuItem(tabMenu);
}
}
use of org.zaproxy.zap.view.ZapMenuItem in project zaproxy by zaproxy.
the class MainMenuBar method getMenuContextExport.
private ZapMenuItem getMenuContextExport() {
if (menuFileContextExport == null) {
menuFileContextExport = new ZapMenuItem("menu.file.context.export");
menuFileContextExport.addActionListener(new java.awt.event.ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
getMenuFileControl().exportContext();
}
});
}
return menuFileContextExport;
}
Aggregations