Examples of NavCommand


Examples of org.locationtech.udig.project.command.NavCommand

            return; // no go
        }
       
        //NavigationCommandFactory navigate = NavigationCommandFactory.getInstance();

        NavCommand show = new SetViewportBBoxCommand(areaOfInterest, world);
        imap.sendCommandASync( show );
    }
View Full Code Here

Examples of org.locationtech.udig.project.command.NavCommand

   * @see org.locationtech.udig.project.internal.command.navigation.NavCommand#setViewportModel(org.locationtech.udig.project.ViewportModelControl)
   */
  public void setViewportModel(ViewportModel model) {
    this.model = model;
    for (Iterator iter = commands.iterator(); iter.hasNext();) {
      NavCommand command = (NavCommand) iter.next();
      command.setViewportModel(model);
    }
  }
View Full Code Here

Examples of org.locationtech.udig.project.command.NavCommand

    model.eSetDeliver(false);
    boolean changedState = false;
    try {
      for (Iterator<? extends MapCommand> iter = commands.iterator(); iter
          .hasNext();) {
        NavCommand command = (NavCommand) iter.next();

        // reset the eSetDeliverState so that the last change will trigger a re-render
        if (!iter.hasNext())
          model.eSetDeliver(previousDeliver);
       
                // initialize command
                command.setMap(getMap());
                command.setViewportModel(model);
              
                changedState |= runCommand(command, monitor);
      }
      monitor.done();
    } finally {
View Full Code Here

Examples of org.locationtech.udig.project.command.NavCommand

//                System.out.println("current scale:" + currentscale);
//                System.out.println("aaaanew scale:" + newscale);
//            }
           
            //compute new bbox for
            NavCommand setFinal = new AbstractNavCommand(){

                @Override
                protected void runImpl( IProgressMonitor monitor ) throws Exception {
                    model.setBounds(newbounds);
                }
View Full Code Here

Examples of org.locationtech.udig.project.command.NavCommand

         */
        public void mouseReleased( MapMouseEvent e ) {
            if (dragging) {
                ((ViewportPane) context.getMapDisplay()).enableDrawCommands(true);
                Point end = e.getPoint();
                NavCommand finalPan = new PanCommand((start.x - end.x), (start.y - end.y));

                // clear any events before we try to pan. This dramatically reduces the number
                // of images drawn to the screen in the wrong spot
                ((ViewportPane) getContext().getMapDisplay()).update();

View Full Code Here

Examples of org.locationtech.udig.project.command.NavCommand

                // System.out.println("current scale:" + currentscale);
                // System.out.println("aaaanew scale:" + newscale);
                // }

                // compute new bbox for
                NavCommand setFinal = new AbstractNavCommand(){

                    @Override
                    protected void runImpl( IProgressMonitor monitor ) throws Exception {
                        model.setBounds(newbounds);
                    }
View Full Code Here

Examples of org.locationtech.udig.project.command.NavCommand

        IAction tool = ApplicationGIS.getToolManager().getToolAction("org.locationtech.udig.tools.selectionTool", "org.locationtech.udig.tool.edit.edit"); //$NON-NLS-1$ //$NON-NLS-2$
        // could be null if tool.edit plug-in is not in distribution.
        if( tool !=null ){
          tool.run();
        }
        NavCommand zoom = context.getNavigationFactory().createSetViewportBBoxCommand(
                bounds, crs);
        context.sendASyncCommand(zoom);
        composite.getCommands().add(context.getSelectionFactory().createFIDSelectCommand(getLayer(),getFeature()));
        composite.getCommands().add(context.getEditFactory().createSetEditFeatureCommand(getFeature(), getLayer()));
        context.sendASyncCommand(composite);
View Full Code Here

Examples of org.locationtech.udig.project.command.NavCommand

     */
    public void mouseReleased(MapMouseEvent e) {
        if (dragging) {
          ((ViewportPane)context.getMapDisplay()).enableDrawCommands(true);
            Point end=e.getPoint();
            NavCommand finalPan = new PanCommand((start.x-end.x), (start.y-end.y));

            //clear any events before we try to pan.  This dramatically reduces the number
            //of images drawn to the screen in the wrong spot
            ((ViewportPane) getContext().getMapDisplay()).update();
           
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.