Package com.google.gwt.user.client

Examples of com.google.gwt.user.client.Command


  public void dispatchTableMenu(int left, int top) {

      MenuBar menu = new MenuBar(true);
      final PopupPanel menuPopup = new PopupPanel(true);
     
      menu.addItem(new MenuItem("Import...", new Command() {
      public void execute() {
        menuPopup.hide();
        dispatchImportAction();
      }
      }));
      menu.addItem(new MenuItem("Export...", new Command() {
      public void execute() {
        menuPopup.hide();
        exportContents();
      }
      }));
View Full Code Here


  }
 
  private void _doSearch() {
    String searchString = getSearchString();
    enable(false);
    PortalControl.getInstance().searchOntologies(searchString, new Command() {
      public void execute() {
        enable(true);
        textBox.selectAll();
      }
    });
View Full Code Here

      add(focusPanel);
    }

    protected void _processEnterEditing(final char firstKeyForEditing) {
     
      DeferredCommand.addCommand(new Command() {
        public void execute() {
          final TextArea ta = new TextArea();
          String text = contents.getText().trim();
         
          if ( firstKeyForEditing != 0 ) {
View Full Code Here

  /**
   * Prepares the panel for creation of a new ontology using the vine style.
   */
  void createNewMappingOntology() {
    DeferredCommand.addCommand(new Command() {
      public void execute() {
        _getDefaultVineRelationInfosAndCreateNewMappingOntology();
      }
    });
  }
View Full Code Here

      PortalControl.getInstance().notifyActivity(true);
      popup.center();
      popup.setText("Loading ontology contents ...");
      popup.show();
     
      _getOntologyContents(new Command() {
        public void execute() {
          log("reviewAndRegister: calling _doReviewAndRegister");
          _doReviewAndRegister(popup);
        }
      });
View Full Code Here

    return ont_mb;
  }
 
 
  private MenuItem _createMenuItemCreateNewVersion() {
    return new MenuItem("Edit new version", new Command() {
      public void execute() {
        pctrl.editNewVersion();
      }
    });
  }
View Full Code Here

    });

  }
 
  private MenuItem _createMenuItemVersions(final RegisteredOntologyInfo oi) {
    return new MenuItem("Versions", new Command() {
      public void execute() {
        launchVersions(oi);
      }
    });
  }
View Full Code Here

   * @param text the menu item's text
   * @param cmd the command to trigger when the item is selected
   */
  public ExtendedMenuItem(AbstractImagePrototype icon, String text,
      final org.latexlab.docs.client.commands.Command cmd) {
    super("<span>" + icon.getHTML() + "</span> " + text, true, new Command() {
    @Override
    public void execute() {
          CommandEvent.fire(cmd);
    }
    });
View Full Code Here

      MenuBar menu = new MenuBar(true);
      final PopupPanel menuPopup = new PopupPanel(true);
     
      if ( row >= FIRST_REGULAR_ROW ) {
        menu.addItem(new MenuItem("Insert row above", new Command() {
          public void execute() {
            _insertRow(row, flexTable.getCellCount(row));
            menuPopup.hide();
          }
        }));
      }
      menu.addItem(new MenuItem("Insert row below", new Command() {
      public void execute() {
        _insertRow(row + 1, flexTable.getCellCount(row));
        menuPopup.hide();
      }
      }));
     
      if ( row >= FIRST_REGULAR_ROW ) {
        menu.addSeparator();
        menu.addItem(new MenuItem("Delete row", new Command() {
          public void execute() {
            _deleteRow(row);
            menuPopup.hide();
          }
        }));
View Full Code Here

    int top = ww.getAbsoluteTop();

      MenuBar menu = new MenuBar(true);
      final PopupPanel menuPopup = new PopupPanel(true);
     
      menu.addItem(new MenuItem("Insert column right", new Command() {
      public void execute() {
        _insertCol(col + 1);
        menuPopup.hide();
      }
      }));
      menu.addItem(new MenuItem("Insert column left", new Command() {
      public void execute() {
        _insertCol(col);
        menuPopup.hide();
      }
      }));
     
      // do not allow to remove the client column if it's the only one:
      if ( flexTable.getCellCount(0) > 2 ) {
        menu.addSeparator();
        menu.addItem(new MenuItem("Delete column", new Command() {
        public void execute() {
          _deleteCol(col);
          menuPopup.hide();
        }
        }));
View Full Code Here

TOP

Related Classes of com.google.gwt.user.client.Command

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.