[java] mouse events

Started by
0 comments, last by pcvsee 23 years, 1 month ago
how do you check if a certain mouse button was pressed or clicked? for example, how will i know if the right mouse button was clicked?
Advertisement
this.addMouseListener(new java.awt.event.MouseAdapter()
{
public void mousePressed(MouseEvent e)
{
if (e.isMetaDown())
System.out.println("Right Click");
}
});

''this'' is an applet

This topic is closed to new replies.

Advertisement