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

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

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

JComboBox.addMouseListener介绍

暂无

代码示例

代码示例来源:origin: com.jidesoft/jide-oss

@Override
protected void installListeners() {
  super.installListeners();
  if (_rolloverListener == null) {
    _rolloverListener = createRolloverListener();
  }
  comboBox.addMouseListener(_rolloverListener);
}

代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/skinlf

protected void installListeners() {
 super.installListeners();
 rolloverListener = createRolloverListener();
 comboBox.addMouseListener(rolloverListener);
}

代码示例来源:origin: org.zaproxy/zap

public void addFieldListener(String fieldLabel, MouseAdapter listener) {
  Component c = this.fieldMap.get(fieldLabel);
  if (c != null) {
    if (c instanceof ZapTextField) {
      ((ZapTextField)c).addMouseListener(listener);
    } else if (c instanceof ZapTextArea) {
      ((ZapTextArea)c).addMouseListener(listener);
    } else if (c instanceof JPasswordField) {
      ((JPasswordField)c).addMouseListener(listener);
    } else if (c instanceof JComboBox) {
      ((JComboBox<?>)c).addMouseListener(listener);
    } else {
      logger.error("Unrecognised field class " + fieldLabel + ": " + c.getClass().getCanonicalName());
    }
  }
}

代码示例来源:origin: net.sf.nimrod/nimrod-laf

protected  void installListeners() {
 super.installListeners();
 miML = new MiML();
 comboBox.addMouseListener( miML);
 comboBox.addFocusListener( miML);
}

代码示例来源:origin: khuxtable/seaglass

@Override
protected void installListeners() {
  comboBox.addPropertyChangeListener(this);
  comboBox.addMouseListener(buttonHandler);
  editorFocusHandler = new EditorFocusHandler(comboBox);
  super.installListeners();
}

代码示例来源:origin: org.appdapter/org.appdapter.lib.gui

setLayout(new BorderLayout());
add("Center", combo);
combo.addMouseListener(this);
combo.setEditable(isStringChooser || useStringProxies);

代码示例来源:origin: abc9070410/JComicDownloader

private JComboBox getComboBox( String[] strings, int selectedIndex )
  {
    JComboBox comboBox = new JComboBox( strings );
    if ( SetUp.getUsingBackgroundPicOfOptionFrame() )
    { // 若設定為透明,就用預定字體。
      comboBox.setForeground( SetUp.getOptionFrameOtherDefaultColor() );
      comboBox.setOpaque( false );
      comboBox.addMouseListener( this );
    }

    ListCellRenderer renderer = new ComplexCellRenderer();
    comboBox.setRenderer( renderer );
    comboBox.setSelectedIndex( selectedIndex );
    comboBox.setFont( SetUp.getDefaultFont() );

    return comboBox;
  }
}

代码示例来源:origin: nativelibs4java/JavaCL

examplesCombo.addItem(example);
examplesCombo.addMouseListener(new MouseAdapter() { public void mouseClicked(MouseEvent e) {
  String t = sourceTextArea.getText();
  if (t.trim().length() > 0)

代码示例来源:origin: abc9070410/JComicDownloader

skinBox.addMouseListener( this );

代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/toniclf

comboBox.addMouseListener(popupMouseListener);

相关文章

JComboBox类方法