Examples of Button


Examples of org.bukkit.material.Button

        // just print a generic message
        ChangedSign info = null;
        if (!SignUtil.isSign(destination)) {
            if (destination.getType() == Material.STONE_BUTTON || destination.getType() == Material.WOOD_BUTTON) {

                Button button = (Button) destination.getState().getData();
                if (SignUtil.isSign(destination.getRelative(button.getAttachedFace(), 2)))
                    info = BukkitUtil.toChangedSign(destination.getRelative(button.getAttachedFace(), 2));
            }
            if (info == null)
                return;
        } else
            info = BukkitUtil.toChangedSign(destination);
View Full Code Here

Examples of org.damour.base.client.ui.buttons.Button

    this.permissibleObject = permissibleObject;

    final User user = AuthenticationHandler.getInstance().getUser();

    setText("E-mail to Friends");
    Button ok = new Button("OK");
    ok.addClickHandler(new ClickHandler() {
      public void onClick(ClickEvent event) {
        // build a map of addresses/names from table
        String toAddresses = "";
        for (int i = 0; i < NUM_ADDRESSES; i++) {
          String address = ((TextBox) emailAddressTable.getWidget(i, 0)).getText();
          if (!StringUtils.isEmpty(address)) {
            String name = ((TextBox) emailAddressTable.getWidget(i, 1)).getText();
            if (StringUtils.isEmpty(name)) {
              name = address;
            }
            toAddresses += address + ";" + name + ";";
          }
        }
        String fromAddress = null;
        String fromName = null;
        if (user == null) {
          fromAddress = userEmailTextBox.getText();
          fromName = userTextBox.getText();
        } else {
          fromAddress = user.getEmail();
          fromName = user.getFirstname();
        }
        if (StringUtils.isEmpty(fromName)) {
          fromName = fromAddress;
        }
        if (StringUtils.isEmpty(fromAddress)) {
          MessageDialogBox messageDialog = new MessageDialogBox("Error", "You must enter your email address.", false, false, true);
          messageDialog.center();
          return;
        }
        sendEmail(permissibleObject, subject, message, fromAddress, fromName, toAddresses);
        hide();
      }
    });
    Button cancel = new Button("Cancel");
    cancel.addClickHandler(new ClickHandler() {
      public void onClick(ClickEvent event) {
        hide();
      }
    });
    final HorizontalPanel dialogButtonPanel = new HorizontalPanel();
View Full Code Here

Examples of org.dspace.app.xmlui.wing.element.Button

    }
 

  private void addAdministratorOnlyButton(Cell cell, String buttonName, Message buttonLabel) throws WingException, SQLException
  {
      Button button = cell.addButton(buttonName);
      button.setValue(buttonLabel);
      if (!AuthorizeManager.isAdmin(context))
      {
        // Only admins can create or delete
        button.setDisabled();
        cell.addHighlight("fade").addContent(T_sysadmins_only);
      }
  }
View Full Code Here

Examples of org.eclipse.draw2d.Button

  }
 
  protected Clickable createButton() {
    final Color foreground = CommonUIPlugin.getDefault().getColorRegistry().get(IDetailsColors.COLOR_DARK_SHADOW);
    final Color background = CommonUIPlugin.getDefault().getColorRegistry().get(IDetailsColors.COLOR_TRAY_BACKGROUND);
    Button result = new ArrowButton() {
      protected void paintBorder(Graphics graphics) {
        graphics.setForegroundColor(foreground);
        Rectangle r = getBounds().getCopy();
        r.shrink(0, 2);
        r.width -= 1;
        graphics.drawRectangle(r);
      }
    };
    result.setBackgroundColor(background);
    // sets the triangle color
    ((Triangle)result.getChildren().get(0)).setBackgroundColor(foreground);
    return result;
  }
View Full Code Here

Examples of org.eclipse.swt.widgets.Button

        layout.numColumns = 3;
        layout.marginHeight = 0;
        layout.marginWidth = 0;
        this.setLayout(layout);
       
        _refresh = new Button(this, SWT.PUSH);
        _refresh.setImage(Activator.getDefault().getImageRegistry().get(Activator.IMAGE_REFRESH));
        _refresh.setToolTipText("refresh");
        GridData gd = new GridData();
        gd.horizontalSpan = 3;
        gd.horizontalAlignment = SWT.END;
View Full Code Here

Examples of org.eclipse.swt.widgets.Button

    comboTemplateData.horizontalSpan = 2;
    _comboTemplateList.setLayoutData(comboTemplateData);
   
    Label label = new Label(_container, SWT.NONE);
    label.setText("Register as new application:");
    _chkCreateContentStore = new Button(_container, SWT.CHECK);
    _chkCreateContentStore.setText("yes");
    _chkCreateContentStore.setSelection(true);
   
    _chkCreateContentStore.addSelectionListener(new SelectionAdapter() {
View Full Code Here

Examples of org.eclipse.swt.widgets.Button

        _lblRemoteDatabaseName.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
       
        label = new Label(_container, SWT.NONE);
       
        GridData chkGridData = new GridData(GridData.FILL_HORIZONTAL);       
        _chkCopyLocalContent = new Button(_container, SWT.CHECK);
        _chkCopyLocalContent.setText("copy local content");
        _chkCopyLocalContent.setLayoutData(chkGridData);
        _chkCopyLocalContent.setEnabled(false);
       
        label = new Label(_container, SWT.NONE);
       
        _chkIncludeACL = new Button(_container, SWT.CHECK);
        _chkIncludeACL.setText("include ACL on content copy");
        _chkIncludeACL.setLayoutData(GridDataFactory.copyData(chkGridData));
        _chkIncludeACL.setEnabled(false);
       
        _multiTaskStatusControl = new MultiTaskStatusControl(_container, SWT.NONE);
View Full Code Here

Examples of org.eclipse.swt.widgets.Button

        label = new Label(container, SWT.NONE);
        label.setText("Options:");
       
        GridData chkGridData = new GridData(GridData.FILL_HORIZONTAL);
           
        _chkCopyLocalContent = new Button(container, SWT.CHECK);
        _chkCopyLocalContent.setText("copy local content");
        _chkCopyLocalContent.setLayoutData(chkGridData);
        _chkCopyLocalContent.addSelectionListener(new SelectionListener() {
           
            public void widgetSelected(SelectionEvent e) {
                if (_chkCopyLocalContent.getSelection()) {
                    _chkIncludeACL.setEnabled(true);
                } else {
                    _chkIncludeACL.setEnabled(false);
                }               
                performValidation();
            }
           
            public void widgetDefaultSelected(SelectionEvent e) {
                if (_chkCopyLocalContent.getSelection()) {
                    _chkIncludeACL.setEnabled(true);
                } else {
                    _chkIncludeACL.setEnabled(false);
                }   
                performValidation();
            }
        });
       
        Label filler = new Label(container, SWT.NONE);
       
        _chkIncludeACL = new Button(container, SWT.CHECK);
        _chkIncludeACL.setText("include ACL on content copy");
        _chkIncludeACL.setLayoutData(GridDataFactory.copyData(chkGridData));
        _chkIncludeACL.addSelectionListener(this);

        _chkCopyLocalContent.setSelection(true);
View Full Code Here

Examples of org.eclipse.swt.widgets.Button

    lblLocation.setText("Location:");
    _tmplFile = new Text(composite, SWT.BORDER);
    _tmplFile.setLayoutData(txtStyle);
    _tmplFile.addModifyListener(this);

    _btnBrowse = new Button(composite, SWT.PUSH);
    _btnBrowse.setText("...");
    _btnBrowse.addSelectionListener(new SelectionAdapter() {
      public void widgetSelected(org.eclipse.swt.events.SelectionEvent e) {
        handleBrowse();
      }
View Full Code Here

Examples of org.eclipse.swt.widgets.Button

    lblPW.setText("Password:");
    _srvPW = new Text(composite, SWT.PASSWORD | SWT.BORDER);
    _srvPW.setLayoutData(txtStyle);
    _srvPW.addModifyListener(this);

    _btnTestConnection = new Button(composite, SWT.PUSH);
    _btnTestConnection.addSelectionListener(new SelectionListener() {

      public void widgetDefaultSelected(SelectionEvent e) {
      }
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.