Package org.jmol.awt
Class Mouse
java.lang.Object
org.jmol.awt.Mouse
- All Implemented Interfaces:
KeyListener,MouseListener,MouseMotionListener,MouseWheelListener,EventListener,GenericMouseInterface
class Mouse
extends Object
implements MouseWheelListener, MouseListener, MouseMotionListener, KeyListener, GenericMouseInterface
formerly org.jmol.viewer.MouseManager14
methods required by Jmol that access java.awt.event
private to org.jmol.awt
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate booleanprivate Stringprivate EventManagerprivate intprivate intprivate Viewerprivate booleanprivate intprivate int -
Constructor Summary
ConstructorsConstructorDescriptionMouse(double privateKey, PlatformViewer vwr, Object odisplay) Mouse is the listener for all events. -
Method Summary
Modifier and TypeMethodDescriptionprivate voidaddKeyBuffer(char ch) private static intapplyLeftMouse(int modifiers) private voidcheckElementSelected(char ch) voidclear()private voidvoiddispose()voidkeyPressed(KeyEvent ke) voidkeyReleased(KeyEvent ke) voidprivate voidmouseClicked(long time, int x, int y, int modifiers, int clickCount) voidprivate voidmouseDragged(long time, int x, int y) voidprivate voidmouseEntered(long time, int x, int y) voidprivate voidmouseExited(long time, int x, int y) voidprivate voidmouseMoved(long time, int x, int y, int modifiers) voidprivate voidmousePressed(long time, int x, int y, int modifiers, boolean isPopupTrigger) voidprivate voidmouseReleased(long time, int x, int y, int modifiers) voidprivate voidmouseWheel(long time, int rotation, int modifiers) voidbooleanprocessEvent(int id, int x, int y, int modifiers, long time) voidprocessKeyEvent(Object event) voidprocessTwoPointGesture(float[][][] touches) private void
-
Field Details
-
vwr
-
manager
-
keyBuffer
-
isMouseDown
private boolean isMouseDown -
wheeling
private boolean wheeling -
modifiersDown
private int modifiersDown -
xWhenPressed
private int xWhenPressed -
yWhenPressed
private int yWhenPressed -
modifiersWhenPressed10
private int modifiersWhenPressed10
-
-
Constructor Details
-
Mouse
Mouse(double privateKey, PlatformViewer vwr, Object odisplay) Mouse is the listener for all events.- Parameters:
privateKey-vwr-odisplay-
-
-
Method Details
-
clear
public void clear()- Specified by:
clearin interfaceGenericMouseInterface
-
dispose
public void dispose()- Specified by:
disposein interfaceGenericMouseInterface
-
processEvent
public boolean processEvent(int id, int x, int y, int modifiers, long time) - Specified by:
processEventin interfaceGenericMouseInterface
-
mouseClicked
- Specified by:
mouseClickedin interfaceMouseListener
-
mouseEntered
- Specified by:
mouseEnteredin interfaceMouseListener
-
mouseExited
- Specified by:
mouseExitedin interfaceMouseListener
-
mousePressed
- Specified by:
mousePressedin interfaceMouseListener
-
mouseReleased
- Specified by:
mouseReleasedin interfaceMouseListener
-
mouseDragged
- Specified by:
mouseDraggedin interfaceMouseMotionListener
-
mouseMoved
- Specified by:
mouseMovedin interfaceMouseMotionListener
-
mouseWheelMoved
- Specified by:
mouseWheelMovedin interfaceMouseWheelListener
-
keyTyped
- Specified by:
keyTypedin interfaceKeyListener
-
keyPressed
- Specified by:
keyPressedin interfaceKeyListener
-
keyReleased
- Specified by:
keyReleasedin interfaceKeyListener
-
processKeyEvent
- Specified by:
processKeyEventin interfaceGenericMouseInterface
-
clearKeyBuffer
private void clearKeyBuffer() -
addKeyBuffer
private void addKeyBuffer(char ch) -
checkElementSelected
private void checkElementSelected(char ch) -
sendKeyBuffer
private void sendKeyBuffer() -
mouseEntered
private void mouseEntered(long time, int x, int y) -
mouseExited
private void mouseExited(long time, int x, int y) -
mouseClicked
private void mouseClicked(long time, int x, int y, int modifiers, int clickCount) - Parameters:
time-x-y-modifiers-clickCount-
-
mouseMoved
private void mouseMoved(long time, int x, int y, int modifiers) -
mouseWheel
private void mouseWheel(long time, int rotation, int modifiers) -
mousePressed
private void mousePressed(long time, int x, int y, int modifiers, boolean isPopupTrigger) - Parameters:
time-x-y-modifiers-isPopupTrigger-
-
mouseReleased
private void mouseReleased(long time, int x, int y, int modifiers) -
mouseDragged
private void mouseDragged(long time, int x, int y) -
applyLeftMouse
private static int applyLeftMouse(int modifiers) -
processTwoPointGesture
public void processTwoPointGesture(float[][][] touches) - Specified by:
processTwoPointGesturein interfaceGenericMouseInterface
-