Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Mouse Listener on JComboBox

 
Sajee Joseph
Ranch Hand
Posts: 200
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I need to implement a mouse listener on the JList part of JCombo box. As i have read, Swing's implementation of a ComboBox --is a combination of a text field and drop-down list .
So when i do
Component[] comps = c.getComponents();
for(int i = 0; i < comps.length; i++)
{
comps[i].addMouseListener(this);
}
The mouse listents to mouse events on the combo. But instead i want the mouse events(like double click) on the list that appears below the JCombo , and not on the JCombo.
How do i do that?
Regards
Saj
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic