Galera,
Tenho a seguinte classe:
public class ApplicationActionBarAdvisor extends ActionBarAdvisor {
private IWorkbenchAction exitAction;
private IWorkbenchAction aboutAction;
private IWorkbenchAction helpAction;
private IWorkbenchAction preferencesAction;
private IWorkbenchAction resetPerspectiveAction;
private ImportAction importAction;
private ExportAction exportAction;
private static IStatusLineManager statusLine;
public ApplicationActionBarAdvisor(IActionBarConfigurer configurer) {
super(configurer);
configurer.getWindowConfigurer().setShowCoolBar(false);
}
protected void makeActions(final IWorkbenchWindow window) {
exitAction = ActionFactory.QUIT.create(window);
exitAction.setText("Sair");
register(exitAction);
aboutAction = ActionFactory.ABOUT.create(window);
register(aboutAction);
helpAction = ActionFactory.HELP_CONTENTS.create(window);
register(helpAction);
resetPerspectiveAction = ActionFactory.RESET_PERSPECTIVE.create(window);
resetPerspectiveAction.setText("Reorganizar janelas");
register(resetPerspectiveAction);
preferencesAction = ActionFactory.PREFERENCES.create(window);
preferencesAction.setText("Preferências");
register(preferencesAction);
importAction = new ImportAction(window);
exportAction = new ExportAction(window);
}
protected void fillMenuBar(IMenuManager menuBar) {
MenuManager fileMenu = new MenuManager("&Mesa Telefonista", IWorkbenchActionConstants.M_FILE);
menuBar.add(fileMenu);
fileMenu.add(importAction);
fileMenu.add(exportAction);
fileMenu.add(exitAction);
menuBar.add(preferencesAction);
MenuManager janelasMenu = new MenuManager("&Janelas", "janelas");
menuBar.add(janelasMenu);
janelasMenu.add(resetPerspectiveAction);
MenuManager helpMenu = new MenuManager("&Ajuda", "help");
helpMenu.add(helpAction);
helpMenu.add(aboutAction);
menuBar.add(helpMenu);
}
@Override
protected void fillCoolBar(ICoolBarManager coolBar) {
}
@Override
protected void fillStatusLine(IStatusLineManager statusLine) {
ApplicationActionBarAdvisor.statusLine = statusLine;
}
public static IStatusLineManager getStatusLine() {
return statusLine;
}
}
Como adicionar nela, um Menu que chame uma tela feita em Swing? Tô tentando com a classe org.eclipse.swt.awt.SWT_AWT mas até agora nada.