Package org.jbpm.ui.dialog

Examples of org.jbpm.ui.dialog.UpdateSwimlaneNameDialog


    private class CreateSwimlaneSelectionListener extends SelectionAdapter {

        @Override
        public void widgetSelected(SelectionEvent e) {
            UpdateSwimlaneNameDialog dialog = new UpdateSwimlaneNameDialog(getDefinition(), true);
            if (dialog.open() == IDialogConstants.OK_ID) {
                Swimlane newSwimlane = JpdlVersionRegistry.getElementTypeDefinition(getDefinition().getJpdlVersion(), "swimlane").createElement();
                newSwimlane.setParent(getDefinition());
                newSwimlane.setName(dialog.getName());
                newSwimlane.setDelegationClassName(Swimlane.DELEGATION_CLASS_NAME);
                getDefinition().addSwimlane(newSwimlane);
                viewer.setSelection(new StructuredSelection(newSwimlane));
            }
        }
View Full Code Here


        @Override
        public void widgetSelected(SelectionEvent e) {
            IStructuredSelection selection = (IStructuredSelection) viewer.getSelection();
            Swimlane swimlane = (Swimlane) selection.getFirstElement();

            UpdateSwimlaneNameDialog renameDialog = new UpdateSwimlaneNameDialog(swimlane.getProcessDefinition(), false);
            renameDialog.setName(swimlane.getName());
            int result = renameDialog.open();
            String newName = renameDialog.getName();
            boolean useLtk = renameDialog.isProceedRefactoring();
            if (result != IDialogConstants.OK_ID) {
                return;
            }
            IResource projectRoot = editor.getDefinitionFile().getParent();
            if (useLtk) {
View Full Code Here

            item.fill(menu, -1);
        }
    }

    private void createSwimlane() {
        UpdateSwimlaneNameDialog newSwimlaneDialog = new UpdateSwimlaneNameDialog(currentDefinition, true);
        if (newSwimlaneDialog.open() == IDialogConstants.OK_ID) {
            String swimlaneName = newSwimlaneDialog.getName();
            Swimlane newSwimlane = JpdlVersionRegistry.getElementTypeDefinition(currentDefinition.getJpdlVersion(), "swimlane").createElement();
            newSwimlane.setParent(currentDefinition);
            newSwimlane.setName(swimlaneName);
            newSwimlane.setDelegationClassName(Swimlane.DELEGATION_CLASS_NAME);
            currentDefinition.addSwimlane(newSwimlane);
View Full Code Here

TOP

Related Classes of org.jbpm.ui.dialog.UpdateSwimlaneNameDialog

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.