com.vaadin.ui.CheckBox.addListener()方法的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(4.8k)|赞(0)|评价(0)|浏览(125)

本文整理了Java中com.vaadin.ui.CheckBox.addListener()方法的一些代码示例,展示了CheckBox.addListener()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。CheckBox.addListener()方法的具体详情如下:
包路径:com.vaadin.ui.CheckBox
类名称:CheckBox
方法名:addListener

CheckBox.addListener介绍

暂无

代码示例

代码示例来源:origin: com.vaadin/vaadin-server

@Override
public Registration addBlurListener(BlurListener listener) {
  return addListener(BlurEvent.EVENT_ID, BlurEvent.class, listener,
      BlurListener.blurMethod);
}

代码示例来源:origin: com.vaadin/vaadin-server

@Override
public Registration addFocusListener(FocusListener listener) {
  return addListener(FocusEvent.EVENT_ID, FocusEvent.class, listener,
      FocusListener.focusMethod);
}

代码示例来源:origin: fi.vm.sade.organisaatio/organisaatio-ui-widgets

private CheckBox initializeCheckbox(String messageKey, String debugId, String dataSourceProp, VerticalLayout parentC) {
  CheckBox cb = new CheckBox(I18N.getMessage(messageKey));
  cb.setDebugId(createDebugId(debugId));
  cb.setImmediate(true);
  //model.setSuunnitellut(true);
  cb.setPropertyDataSource(new NestedMethodProperty(model, dataSourceProp));
  cb.addListener(new Property.ValueChangeListener() {
    @Override
    public void valueChange(ValueChangeEvent event) {
      //DEBUGSAWAY:log.debug("checkbox was clicked!!!");
      tree.reloadWithSearchData(model);
    }
  });
  parentC.addComponent(cb);
  return cb;
}

代码示例来源:origin: org.aperteworkflow/editor

private void initComponent() {
  roleNameLabel = new Label(queueRolePermission.getRoleName());
  browsingAllowedCheckbox = new CheckBox();
  browsingAllowedCheckbox.setCaption("browsing allowed");
  browsingAllowedCheckbox.addListener(new Button.ClickListener() {
    @Override
    public void buttonClick(Button.ClickEvent clickEvent) {
      if (Boolean.TRUE.equals(queueRolePermission.isBrowsingAllowed())) {
        queueRolePermission.setBrowsingAllowed(false);
      } else {
        queueRolePermission.setBrowsingAllowed(true); // we handle null as well here
      }
    }
  });
  
  if (Boolean.TRUE.equals(queueRolePermission.isBrowsingAllowed())) {
    browsingAllowedCheckbox.setValue(true);
  }
  deleteButton = new Button();
  deleteButton.setCaption("  X  ");
  deleteButton.setStyleName(BaseTheme.BUTTON_LINK);
  deleteButton.addListener(new Button.ClickListener() {
    @Override
    public void buttonClick(Button.ClickEvent event) {
      handler.removeQueueRolePermissionBox(QueueRolePermissionBox.this);
    }
  });
}

代码示例来源:origin: apache/ace

registerCB.addListener(new Button.ClickListener() {
  public void buttonClick(ClickEvent event) {
    if (event.getButton().booleanValue()) {
autoApproveCB.addListener(new Button.ClickListener() {
  public void buttonClick(ClickEvent event) {
    target.setAutoApprove(event.getButton().booleanValue());

代码示例来源:origin: org.activiti/activiti-explorer

nowCheckBox.addStyleName(ExplorerLayout.STYLE_PROCESS_DEFINITION_SUSPEND_CHOICE);
nowCheckBox.setImmediate(true);
nowCheckBox.addListener(new ClickListener() {
 public void buttonClick(ClickEvent event) {
  if (nowCheckBox.booleanValue() == true) {
dateCheckBox.addStyleName(ExplorerLayout.STYLE_PROCESS_DEFINITION_SUSPEND_CHOICE);
dateCheckBox.setImmediate(true);
dateCheckBox.addListener(new ClickListener() {
 public void buttonClick(ClickEvent event) {
  if (dateCheckBox.booleanValue() == true) {

代码示例来源:origin: org.apache.ace/org.apache.ace.target.mgmt.ui

registerCB.addListener(new Button.ClickListener() {
  public void buttonClick(ClickEvent event) {
    if (event.getButton().booleanValue()) {
autoApproveCB.addListener(new Button.ClickListener() {
  public void buttonClick(ClickEvent event) {
    target.setAutoApprove(event.getButton().booleanValue());

代码示例来源:origin: org.aperteworkflow/gui-commons

public OptionalDateField(I18NSource messageSource) {
  HorizontalLayout layout = new HorizontalLayout();
  layout.setSpacing(true);
  layout.setWidth("100%");
  maxRangeCheckBox = new CheckBox(messageSource.getMessage("date.field.max.range"));
  maxRangeCheckBox.setValue(false);
  maxRangeCheckBox.setImmediate(true);
  maxRangeCheckBox.setWidth("100%");
  maxRangeCheckBox.addListener(new ValueChangeListener() {
    public void valueChange(com.vaadin.data.Property.ValueChangeEvent event) {
      toggleDateField(maxRangeCheckBox.booleanValue() ? null : new Date());
    }
  });
  dateField = new PopupDateField();
  dateField.setImmediate(true);
  dateField.setDateFormat(VaadinUtility.SIMPLE_DATE_FORMAT_STRING);
  dateField.setWidth("100px");
  dateField.setResolution(DateField.RESOLUTION_DAY);
  layout.addComponent(dateField);
  layout.addComponent(maxRangeCheckBox);
  layout.setExpandRatio(maxRangeCheckBox, 1.0F);
  setCompositionRoot(layout);
}

代码示例来源:origin: org.activiti/activiti-explorer

useSSL.setImmediate(true);
imapForm.getLayout().addComponent(useSSL);
useSSL.addListener(new ValueChangeListener() {
 public void valueChange(ValueChangeEvent event) {
  imapPort.setValue( ((Boolean) useSSL.getValue()) ? 993 : 143);

代码示例来源:origin: org.apache.ace/org.apache.ace.webui.vaadin

dynamicCheckBox.setImmediate(true);
dynamicCheckBox.setValue(Boolean.TRUE);
dynamicCheckBox.addListener(new Button.ClickListener() {
  public void buttonClick(ClickEvent event) {
    m_dynamicRelations = event.getButton().booleanValue();

相关文章