javax.swing.JComboBox.removeItemListener()方法的使用及代码示例

x33g5p2x  于2022-01-21 转载在 其他  
字(5.5k)|赞(0)|评价(0)|浏览(110)

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

JComboBox.removeItemListener介绍

暂无

代码示例

代码示例来源:origin: groovy/groovy-core

public synchronized void syntheticUnbind() {
  boundComboBox.removePropertyChangeListener("model", this);
  boundComboBox.removeItemListener(this);
  boundComboBox = null;
}

代码示例来源:origin: groovy/groovy-core

public synchronized void syntheticUnbind() {
  boundComboBox.removePropertyChangeListener("model", this);
  boundComboBox.removeItemListener(this);
  boundComboBox = null;
}

代码示例来源:origin: winterDroid/android-drawable-importer-intellij-plugin

private void updateSearch() {
  searchField.removeItemListener(searchFieldListener);
  searchField.setSelectedItem(controller.getSelectedAsset());
  searchField.addItemListener(searchFieldListener);
}

代码示例来源:origin: winterDroid/android-drawable-importer-intellij-plugin

private void updateSearch() {
  searchField.removeItemListener(searchFieldListener);
  searchField.setSelectedItem(controller.getSelectedAsset());
  searchField.addItemListener(searchFieldListener);
}

代码示例来源:origin: nl.cloudfarming.client/geometry-shape-type

/**
   * Remove an ItemListener from the import type combo box
   *
   * @param listener
   */
  public void removeImportTypeListener(ItemListener listener) {
    typeBox.removeItemListener(listener);
    shapeTypeBox.removeItemListener(listener);
  }
}

代码示例来源:origin: nl.cloudfarming.client/field-shape-type

/**
   * Remove an ItemListener from the import type combo box
   *
   * @param listener
   */
  public void removeImportTypeListener(ItemListener listener) {
    typeBox.removeItemListener(listener);
  }
}

代码示例来源:origin: com.google.code.validationframework/validationframework-swing

/**
 * @see Disposable#dispose()
 */
@Override
public void dispose() {
  // Unhook from component
  component.removeItemListener(eventAdapter);
}

代码示例来源:origin: com.eas.platypus/platypus-js-scalable-widget

@Override
  public void itemStateChanged(ItemEvent e) {
    SwingUtilities.invokeLater(new Runnable() {
      @Override
      public void run() {
        lppm.setVisible(false);
      }
    });
    lcombo.removeItemListener(this);
  }
};

代码示例来源:origin: org.apache.cayenne.modeler/cayenne-modeler

@Override
  public void undo() throws CannotUndoException {
    comboBox.removeItemListener(undoItemListener);
    try {
      comboBox.setSelectedItem(deselectedItem);
    }
    finally {
      comboBox.addItemListener(undoItemListener);
    }
  }
}

代码示例来源:origin: org.codehaus.groovy/groovy-swing

public synchronized void syntheticUnbind() {
  boundComboBox.removePropertyChangeListener("model", this);
  boundComboBox.removeItemListener(this);
  boundComboBox = null;
}

代码示例来源:origin: org.codehaus.groovy/groovy-jdk14

public synchronized void syntheticUnbind() {
  boundComboBox.removePropertyChangeListener("model", this);
  boundComboBox.removeItemListener(this);
  boundComboBox = null;
}

代码示例来源:origin: nl.cloudfarming.client/geometry-shape-type

public void removeItemListener(ItemListener listener) {
    for (Component component : this.getComponents()) {
      if (component instanceof JComboBox) {
        ((JComboBox) component).removeItemListener(listener);
      }
    }
  }
}

代码示例来源:origin: cytoscape.coreplugins/rfilters

/**
 *  DOCUMENT ME!
 *
 * @param comparison DOCUMENT ME!
 */
public void setSelectedComparison(String comparison) {
  filter.setComparison(comparison);
  comparisonBox.removeItemListener(this);
  comparisonBox.setSelectedItem(comparison);
  comparisonBox.addItemListener(this);
}

代码示例来源:origin: cytoscape.coreplugins/rfilters

/**
 *  DOCUMENT ME!
 *
 * @param target DOCUMENT ME!
 */
public void setTarget(String target) {
  filter.setTarget(target);
  targetBox.removeItemListener(this);
  targetBox.setSelectedItem(target);
  targetBox.addItemListener(this);
}

代码示例来源:origin: cytoscape.coreplugins/rfilters

/**
 *  DOCUMENT ME!
 *
 * @param new_attr DOCUMENT ME!
 */
public void setSelectedAttribute(String new_attr) {
  filter.setSelectedAttribute(new_attr);
  attributeBox.removeItemListener(this);
  attributeBox.setSelectedItem(new_attr);
  attributeBox.addItemListener(this);
}

代码示例来源:origin: fr.ifremer/isis-fish

@Override
public void removeDataBinding() {
  if (fieldSensitivitySimulationSelect != null) {
    JComboBox $target = (JComboBox) $bindingSources.remove("fieldSensitivitySimulationSelect");
    if ($target != null) {
      $target.removeItemListener( JAXXUtil.getEventListener(ItemListener.class, this, "$pr$u0"));
    }
  }
}

代码示例来源:origin: org.codehaus.groovy/groovy-jdk14

public synchronized void syntheticUnbind() {
  boundComboBox.removePropertyChangeListener("model", this);
  boundComboBox.removeItemListener(this);
  boundComboBox = null;
}

代码示例来源:origin: org.icepdf.os/icepdf-viewer

private void applySelectedValue(JComboBox comboBox, Object value) {
  comboBox.removeItemListener(this);
  ValueLabelItem currentItem;
  for (int i = 0; i < comboBox.getItemCount(); i++) {
    currentItem = (ValueLabelItem) comboBox.getItemAt(i);
    if (currentItem.getValue().equals(value)) {
      comboBox.setSelectedIndex(i);
      break;
    }
  }
  comboBox.addItemListener(this);
}

代码示例来源:origin: org.icepdf.os/icepdf-viewer

private void applySelectedValue(JComboBox comboBox, Object value) {
  comboBox.removeItemListener(this);
  ValueLabelItem currentItem;
  for (int i = 0; i < comboBox.getItemCount(); i++) {
    currentItem = (ValueLabelItem) comboBox.getItemAt(i);
    if (currentItem.getValue().equals(value)) {
      comboBox.setSelectedIndex(i);
      break;
    }
  }
  comboBox.addItemListener(this);
}

代码示例来源:origin: org.icepdf.os/icepdf-viewer

private void applySelectedValue(JComboBox comboBox, Object value) {
  comboBox.removeItemListener(this);
  ValueLabelItem currentItem;
  for (int i = 0; i < comboBox.getItemCount(); i++) {
    currentItem = (ValueLabelItem) comboBox.getItemAt(i);
    if (currentItem.getValue().equals(value)) {
      comboBox.setSelectedIndex(i);
      break;
    }
  }
  comboBox.addItemListener(this);
}

相关文章

JComboBox类方法