Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一个“CCombo”框和一个列表。当用户单击其下拉列表时,我希望将 List 的所有项目加载到其中。但问题是,如果用户多次单击下拉菜单,则项目会一次又一次地添加到其中。同时在 UI 上显示这些元素。用户找到重复的项目。
所以我只想知道,我们能否从 CCombo 中删除重复的项目。如果是,请指导我。
使用removeAll()或。remove(int start, int end)_CCombo
removeAll()
remove(int start, int end)
CCombo
参考:http ://help.eclipse.org/indigo/index.jsp?topic=%2Forg.eclipse.platform.doc.isv%2Freference%2Fapi%2Forg%2Feclipse%2Fswt%2Fcustom%2FCCombo.html