Mouse
Date: 2019-10-22

org.jmol.awt

## Class Mouse

- java.lang.Object
- - org.jmol.awt.Mouse

- All Implemented Interfaces:
    java.awt.event.KeyListener, java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.awt.event.MouseWheelListener, java.util.EventListener, GenericMouseInterface

      class Mouse
      extends java.lang.Object
      implements java.awt.event.MouseWheelListener, java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.awt.event.KeyListener, GenericMouseInterface

  formerly org.jmol.viewer.MouseManager14 methods required by Jmol that access java.awt.event private to org.jmol.awt

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `private boolean` | `isMouseDown`
    `private java.lang.String` | `keyBuffer`
    `private EventManager` | `manager`
    `private int` | `modifiersDown`
    `private int` | `modifiersWhenPressed10`
    `private Viewer` | `vwr`
    `private boolean` | `wheeling`
    `private int` | `xWhenPressed`
    `private int` | `yWhenPressed`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `Mouse(double privateKey, PlatformViewer vwr, java.lang.Object odisplay)` Mouse is the listener for all events.

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `private void` | `addKeyBuffer(char ch)`
    `private static int` | `applyLeftMouse(int modifiers)`
    `private void` | `checkElementSelected(char ch)`
    `void` | `clear()`
    `private void` | `clearKeyBuffer()`
    `void` | `dispose()`
    `void` | `keyPressed(java.awt.event.KeyEvent ke)`
    `void` | `keyReleased(java.awt.event.KeyEvent ke)`
    `void` | `keyTyped(java.awt.event.KeyEvent ke)`
    `private void` | `mouseClicked(long time, int x, int y, int modifiers, int clickCount)`
    `void` | `mouseClicked(java.awt.event.MouseEvent e)`
    `private void` | `mouseDragged(long time, int x, int y)`
    `void` | `mouseDragged(java.awt.event.MouseEvent e)`
    `private void` | `mouseEntered(long time, int x, int y)`
    `void` | `mouseEntered(java.awt.event.MouseEvent e)`
    `private void` | `mouseExited(long time, int x, int y)`
    `void` | `mouseExited(java.awt.event.MouseEvent e)`
    `private void` | `mouseMoved(long time, int x, int y, int modifiers)`
    `void` | `mouseMoved(java.awt.event.MouseEvent e)`
    `private void` | `mousePressed(long time, int x, int y, int modifiers, boolean isPopupTrigger)`
    `void` | `mousePressed(java.awt.event.MouseEvent e)`
    `private void` | `mouseReleased(long time, int x, int y, int modifiers)`
    `void` | `mouseReleased(java.awt.event.MouseEvent e)`
    `private void` | `mouseWheel(long time, int rotation, int modifiers)`
    `void` | `mouseWheelMoved(java.awt.event.MouseWheelEvent e)`
    `boolean` | `processEvent(int id, int x, int y, int modifiers, long time)`
    `void` | `processTwoPointGesture(float[][][] touches)`
    `private void` | `sendKeyBuffer()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### vwr

          private Viewer vwr

    - #### manager

          private EventManager manager

    - #### keyBuffer

          private java.lang.String 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 Detail

    - #### Mouse

          Mouse(double privateKey,
                PlatformViewer vwr,
                java.lang.Object odisplay)

      Mouse is the listener for all events.
      Parameters:
        `privateKey` -
        `vwr` -
        `odisplay` -

  - ### Method Detail

    - #### clear

          public void clear()

      Specified by:
        `clear` in interface `GenericMouseInterface`

    - #### dispose

          public void dispose()

      Specified by:
        `dispose` in interface `GenericMouseInterface`

    - #### processEvent

          public boolean processEvent(int id,
                                      int x,
                                      int y,
                                      int modifiers,
                                      long time)

      Specified by:
        `processEvent` in interface `GenericMouseInterface`

    - #### mouseClicked

          public void mouseClicked(java.awt.event.MouseEvent e)

      Specified by:
        `mouseClicked` in interface `java.awt.event.MouseListener`

    - #### mouseEntered

          public void mouseEntered(java.awt.event.MouseEvent e)

      Specified by:
        `mouseEntered` in interface `java.awt.event.MouseListener`

    - #### mouseExited

          public void mouseExited(java.awt.event.MouseEvent e)

      Specified by:
        `mouseExited` in interface `java.awt.event.MouseListener`

    - #### mousePressed

          public void mousePressed(java.awt.event.MouseEvent e)

      Specified by:
        `mousePressed` in interface `java.awt.event.MouseListener`

    - #### mouseReleased

          public void mouseReleased(java.awt.event.MouseEvent e)

      Specified by:
        `mouseReleased` in interface `java.awt.event.MouseListener`

    - #### mouseDragged

          public void mouseDragged(java.awt.event.MouseEvent e)

      Specified by:
        `mouseDragged` in interface `java.awt.event.MouseMotionListener`

    - #### mouseMoved

          public void mouseMoved(java.awt.event.MouseEvent e)

      Specified by:
        `mouseMoved` in interface `java.awt.event.MouseMotionListener`

    - #### mouseWheelMoved

          public void mouseWheelMoved(java.awt.event.MouseWheelEvent e)

      Specified by:
        `mouseWheelMoved` in interface `java.awt.event.MouseWheelListener`

    - #### keyTyped

          public void keyTyped(java.awt.event.KeyEvent ke)

      Specified by:
        `keyTyped` in interface `java.awt.event.KeyListener`

    - #### keyPressed

          public void keyPressed(java.awt.event.KeyEvent ke)

      Specified by:
        `keyPressed` in interface `java.awt.event.KeyListener`

    - #### keyReleased

          public void keyReleased(java.awt.event.KeyEvent ke)

      Specified by:
        `keyReleased` in interface `java.awt.event.KeyListener`

    - #### 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:
        `processTwoPointGesture` in interface `GenericMouseInterface`