Im running a simple JFrame with a JList.
I encountered an issue just like this guy> Java getClickCount on touchscreen
I know it has been posted already but there
Code below is working..
public class MainTest extends JPanel {
public MainTest() {
addMouseListener(new MouseAdapter() {
public void mousePressed(MouseEvent me) {
System.out.println(me.getClickCount());
}
});
}
public static void main(String[] args) {
JFrame frame = new JFrame();
frame.getContentPane().add(new MainTest());
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setSize(200, 200);
frame.setVisible(true);
}
}