[java] mouse events
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?
this.addMouseListener(new java.awt.event.MouseAdapter()
{
public void mousePressed(MouseEvent e)
{
if (e.isMetaDown())
System.out.println("Right Click");
}
});
''this'' is an applet
{
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
Popular Topics
Advertisement