com.ibm.eNetwork.beans.HOD.event
Class ScreenMouseEvent

java.lang.Object
  |
  +--java.util.EventObject
        |
        +--com.ibm.eNetwork.beans.HOD.event.ScreenMouseEvent
All Implemented Interfaces:
java.io.Serializable

public class ScreenMouseEvent
extends java.util.EventObject

Mouse events are generated from 3 distinct components of Screen: The screen text area, the screen OIA, and the border surrounding screen. All pixel coordinates are relative to the component that generated the mouse event. The translatePoint() method allows you to get the pixel coordinates of the screen mouse event as if Screen was one component.

See Also:
ScreenMouseListener, Screen, Terminal, Serialized Form

Field Summary
static short BORDER
          The ScreenMouseEvent occurred on the screen border
static short MOTION_EVENT
          The ScreenMouseEvent was a mouse motion event
static short MOUSE_EVENT
          The ScreenMouseEvent was a mouse event
static short OIA
          The ScreenMouseEvent occurred on the screen OIA
static short TEXT
          The ScreenMouseEvent occurred on the screen text
 
Constructor Summary
ScreenMouseEvent(java.lang.Object source, com.ibm.eNetwork.ECL.ECLPS ps, int type, int comp, java.awt.event.MouseEvent mouseEvt)
          A ScreenMouseEvent.
 
Method Summary
 int getClickCount()
          Returns the number of mouse clicks associated with this event.
 int getCol()
          Returns the column of the mouse click if the mouse type is TEXT or OIA.
 int getComponent()
          Returns the component that this event came from.
 java.awt.event.MouseEvent getMouseEvent()
          Returns the original mouse event from Screen.
 int getRow()
          Returns the row of the mouse click if the mouse type is TEXT or OIA.
 java.awt.Point getRowCol()
          Returns the row and column of the mouse click if the mouse type is TEXT or OIA.
 int getType()
          Returns the event type.
 int getX()
          Returns the x pixel coordinate relative to coordinate (0,0) of the component that generated the mouse event.
 int getY()
          Returns the y pixel coordinate relative to coordinate (0,0) of the component that generated the mouse event.
 java.awt.Point translatePoint()
          Returns the x,y pixel coordinate relative to coordinate (0,0) of Screen.
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

MOUSE_EVENT

public static final short MOUSE_EVENT
The ScreenMouseEvent was a mouse event

MOTION_EVENT

public static final short MOTION_EVENT
The ScreenMouseEvent was a mouse motion event

TEXT

public static final short TEXT
The ScreenMouseEvent occurred on the screen text

OIA

public static final short OIA
The ScreenMouseEvent occurred on the screen OIA

BORDER

public static final short BORDER
The ScreenMouseEvent occurred on the screen border
Constructor Detail

ScreenMouseEvent

public ScreenMouseEvent(java.lang.Object source,
                        com.ibm.eNetwork.ECL.ECLPS ps,
                        int type,
                        int comp,
                        java.awt.event.MouseEvent mouseEvt)
A ScreenMouseEvent. This is fired from the screen to registered ScreenMouseEvent listeners.
Parameters:
source - The source of the event.
type - The Type of the event.
comp - The component that generated the mouse event.
mouseEvt - The original java mouse event from the component.
Method Detail

getType

public int getType()
Returns the event type.

Return values:


getComponent

public int getComponent()
Returns the component that this event came from. Mouse clicks are generated from 3 distinct components of Screen: The screen text area, the screen OIA, and the border surrounding screen.

Return values:


translatePoint

public java.awt.Point translatePoint()
Returns the x,y pixel coordinate relative to coordinate (0,0) of Screen.

getX

public int getX()
Returns the x pixel coordinate relative to coordinate (0,0) of the component that generated the mouse event.
See Also:
getComponent(), translatePoint()

getY

public int getY()
Returns the y pixel coordinate relative to coordinate (0,0) of the component that generated the mouse event.
See Also:
getComponent(), translatePoint()

getRowCol

public java.awt.Point getRowCol()
Returns the row and column of the mouse click if the mouse type is TEXT or OIA. Returns the pixel coordinate if the mouse type is BORDER.

getRow

public int getRow()
Returns the row of the mouse click if the mouse type is TEXT or OIA. If the mouse type is BORDER, then the y pixel coordinate is returned.
See Also:
getComponent(), translatePoint()

getCol

public int getCol()
Returns the column of the mouse click if the mouse type is TEXT or OIA. If the mouse type is BORDER, then the x pixel coordinate is returned.
See Also:
getComponent(), translatePoint()

getMouseEvent

public java.awt.event.MouseEvent getMouseEvent()
Returns the original mouse event from Screen.

getClickCount

public int getClickCount()
Returns the number of mouse clicks associated with this event.