JCombobox 箭头消失
JCombobox arrow disappears
在构造函数中未放置的方法中填充combobox时,combobox的箭头消失
我尝试使用 invokeLater 方法,但没有用。
private void fillProduct(){
this.VALID_FOR_PRODUCT.removeAllItems();
this.VALID_FOR_PRODUCT.addItem(new JChooseItem("ALL", "Any"));
for(Product product : Product.values()){
this.VALID_FOR_PRODUCT.addItem(new JChooseItem(product.getName(), langHelper.getTrans(product.getTranslationKey())));
}
}
我有同样的问题,当我使用方法 removeAllComponents()
而不是 removeAll()
方法时发生了
在构造函数中未放置的方法中填充combobox时,combobox的箭头消失
我尝试使用 invokeLater 方法,但没有用。
private void fillProduct(){
this.VALID_FOR_PRODUCT.removeAllItems();
this.VALID_FOR_PRODUCT.addItem(new JChooseItem("ALL", "Any"));
for(Product product : Product.values()){
this.VALID_FOR_PRODUCT.addItem(new JChooseItem(product.getName(), langHelper.getTrans(product.getTranslationKey())));
}
}
我有同样的问题,当我使用方法 removeAllComponents()
而不是 removeAll()
方法时发生了