/** @generated */ public void run(IAction action) { LoadResourceAction.LoadResourceDialog loadResourceDialog = new LoadResourceAction.LoadResourceDialog(getWindow().getShell()); if (Dialog.OK == loadResourceDialog.open()) { for (Iterator i = loadResourceDialog.getURIs().iterator(); i.hasNext(); ) { openEditor(getWindow().getWorkbench(), (URI) i.next()); } } }
/** * Opens the editors for the files selected using the LoadResourceDialog. * <!-- begin-user-doc --> * <!-- end-user-doc --> * * @generated */ public void run(IAction action) { LoadResourceAction.LoadResourceDialog loadResourceDialog = new LoadResourceAction.LoadResourceDialog(getWindow().getShell()); if (Window.OK == loadResourceDialog.open()) { for (URI uri : loadResourceDialog.getURIs()) { openEditor(getWindow().getWorkbench(), uri); } } }
/** @generated */ public Object execute(ExecutionEvent event) throws ExecutionException { IEditorPart diagramEditor = HandlerUtil.getActiveEditorChecked(event); Shell shell = diagramEditor.getEditorSite().getShell(); assert diagramEditor instanceof DiagramEditor; TransactionalEditingDomain editingDomain = ((DiagramEditor) diagramEditor).getEditingDomain(); LoadResourceAction.LoadResourceDialog loadResourceDialog = new LoadResourceAction.LoadResourceDialog(shell, editingDomain); loadResourceDialog.open(); return null; }