想写一个editable JcomboBox,当focus gained时候从后台读文件,更新Jcombobox的下拉单选项;当从下拉单选择一个选项或者手动编辑的时候,做一系列其他操作。现在的问题是,当focus gain的时候,同时会执行actionPerformed(),我想在从下拉单选择选项的时候才激发actionPerformed(),不知各位达人有没有办法?
调试欢乐多
enter focusGained();
enter actionPerformed();
exit actionPerformed();
enter actionPerformed();
exit actionPerformed();
exit focusGained();
如果是把鼠标移动到别处:
enter actionPerformed();
exit actionPerformed();
enter actionPerformed();
exit actionPerformed();
enter focusLost();
exit focuslost();
太诡异了