【问题标题】:JButton in JList HandlingJList 中的 JButton 处理
【发布时间】:2011-10-12 22:51:27
【问题描述】:

我想在JList 中有一个JButton(用于删除项目)。 当我将JButton 添加到我的JList 时,处理程序不起作用... 我知道它只是渲染的,.. 但我怎么能做到 - 我认识actionPerformed? 也许,有人有code-sn-p?

我添加了一个JPanels 的向量列表,在这些JPanels 里面有我的JButtonJLabel

【问题讨论】:

  • 你能提供一些代码吗?

标签: java jbutton jlist


【解决方案1】:

我认为JTable 会比JList 更好的JComponents,因为在那里你可以实现TableCellEditor,也许是类似输出here 的例子

【讨论】:

猜你喜欢
  • 2016-10-05
  • 2012-11-07
  • 2012-08-02
  • 1970-01-01
  • 2013-12-23
  • 2015-05-11
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多