Package org.locationtech.udig.project.ui.tool

Examples of org.locationtech.udig.project.ui.tool.IToolContext.sendASyncCommand()


        }
        context.getMap().getBlackboard().put(EditToolHandler.CURRENT_SHAPE, null);
        context.getMap().getBlackboard().put(EditToolHandler.EDITSTATE, EditState.NONE);
        context.getMap().getBlackboard().put(ProjectBlackboardConstants.MAP__RENDERING_FILTER,
                null);
        context.sendASyncCommand(context.getEditFactory().createNullEditFeatureCommand());
        context.sendASyncCommand(context.getSelectionFactory().createNoSelectCommand());

        // this code should not be necessary as it should be caught by the events
        // IRenderManager manager = getContext().getMap().getRenderManager();
        // if(manager!=null){
View Full Code Here


        context.getMap().getBlackboard().put(EditToolHandler.CURRENT_SHAPE, null);
        context.getMap().getBlackboard().put(EditToolHandler.EDITSTATE, EditState.NONE);
        context.getMap().getBlackboard().put(ProjectBlackboardConstants.MAP__RENDERING_FILTER,
                null);
        context.sendASyncCommand(context.getEditFactory().createNullEditFeatureCommand());
        context.sendASyncCommand(context.getSelectionFactory().createNoSelectCommand());

        // this code should not be necessary as it should be caught by the events
        // IRenderManager manager = getContext().getMap().getRenderManager();
        // if(manager!=null){
        // manager.refresh(null);
View Full Code Here

        Filter bboxFilter = getBboxFilter(name, newBounds);
        SelectionCommandFactory cmdFactory = SelectionCommandFactory.getInstance();
        UndoableMapCommand selectCommand = cmdFactory.createSelectCommand(layer, bboxFilter);
       
        IToolContext toolContext = ApplicationGIS.createContext(ApplicationGIS.getActiveMap());
        toolContext.sendASyncCommand(selectCommand);
    }
   
    /**
     * Create a bounding box filter from a bounding box.
     *
 
View Full Code Here

            commands.add(new ArrowDrawCommand(new Coordinate(start.x, start.y), new Coordinate(end.x, end.y)));
        }

        IToolContext toolContext = ApplicationGIS.createContext(ApplicationGIS.getActiveMap());
        IDrawCommand compositeCommand = toolContext.getDrawFactory().createCompositeDrawCommand(commands);
        toolContext.sendASyncCommand(compositeCommand);
    }

    /**
     * Create a bounding box filter from a bounding box.
     *
 
View Full Code Here

      IToolContext context = getContext();
      if(context != null){
        UndoableMapCommand clearSelectionCommand = context
            .getSelectionFactory().createNoSelectCommand();

        context.sendASyncCommand(clearSelectionCommand);
      }
    }

  }
View Full Code Here

    private void unselect(SimpleFeature unselectedFeature) {

        IToolContext context = this.mergeView.getContext();
        UndoableMapCommand unselectCommand = context.getSelectionFactory().createNoSelectCommand();

        context.sendASyncCommand(unselectCommand);
    }

    /**
     * Creates the context menu that will be showed when user do a right click on the
     * treeSourceFeatures.
 
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.