List of usage examples for com.intellij.openapi.ui FixedComboBoxEditor FixedComboBoxEditor
FixedComboBoxEditor
From source file:com.android.tools.idea.gradle.structure.editors.KeyValuePane.java
License:Apache License
private ComboBox createComboBox(boolean editable) { ComboBox comboBox = new ComboBox(); comboBox.addItemListener(this); comboBox.setEditor(new FixedComboBoxEditor()); comboBox.setEditable(true);/* w ww .j a va 2s . c om*/ comboBox.setMinLength(60); // Default is only 20 chars JBTextField editorComponent = (JBTextField) comboBox.getEditor().getEditorComponent(); editorComponent.setEditable(editable); editorComponent.getDocument().addDocumentListener(this); return comboBox; }