Package org.locationtech.udig.internal.ui.operations

Examples of org.locationtech.udig.internal.ui.operations.RunOperationsAction


                }
            }

            // if primaryCategories are present, create an "Other" submenu
            if (contextManager.getItems().length != 0) {
                RunOperationsAction action = new RunOperationsAction();
                action.setText(Messages.ToolCategory_other);

                contextManager.add(new Separator());
                contextManager.add(action);
            } else {
                Iterator iter = secondaryCategories.iterator();
                while( iter.hasNext() ) {
                    OperationCategory category = (OperationCategory) iter.next();

                    for( OpAction action : category.getActions() ) {
                        if( selection instanceof IStructuredSelection )
                            action.updateEnablement((IStructuredSelection) selection, true);
                        if (action.isEnabled())
                            contextManager.add(action);
                    }
                    if (iter.hasNext())
                        contextManager.add(new Separator());
                }

                if (getOperationMenuFactory().getActions().size() != 0) {
                    contextManager.add(new Separator());
                }
                for( OpAction action : getOperationMenuFactory().getActions() ) {
                    if( selection instanceof IStructuredSelection )
                        action.updateEnablement((IStructuredSelection) selection, true);
                    if (action.isEnabled()) {
                        contextManager.add(action);
                    }
                }
            }
View Full Code Here

TOP

Related Classes of org.locationtech.udig.internal.ui.operations.RunOperationsAction

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.