com.ibm.eNetwork.beans.HOD.event
Class ScreenEvent
java.lang.Object
|
+--java.util.EventObject
|
+--com.ibm.eNetwork.beans.HOD.event.ScreenEvent
- All Implemented Interfaces:
- java.io.Serializable
- public class ScreenEvent
- extends java.util.EventObject
The Screen Event. This event is fired to ScreenListeners when a URL is selected
or when a cut/paste box is selected, unselected, resized or moved on the Screen.
- See Also:
ScreenListener
,
Screen
,
Terminal
, Serialized Form
Field Summary |
static short |
BOX_SELECTED
A Cut/Paste box was selected, resized, or moved on the Screen |
static short |
BOX_UNSELECTED
A Cut/Paste box was unselected on the Screen |
static short |
URL_SELECTED
A URL string was selected on the Screen |
Constructor Summary |
ScreenEvent(java.lang.Object source,
int type,
java.awt.Insets selected,
java.net.URL url)
Constructs a Screen Event. |
Method Summary |
java.awt.Insets |
getInsets()
Returns the selected box coordinates from Screen. |
int |
getType()
Returns the event type. |
java.net.URL |
getURL()
Returns the URL. |
Methods inherited from class java.util.EventObject |
getSource, toString |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
BOX_SELECTED
public static final short BOX_SELECTED
- A Cut/Paste box was selected, resized, or moved on the Screen
BOX_UNSELECTED
public static final short BOX_UNSELECTED
- A Cut/Paste box was unselected on the Screen
URL_SELECTED
public static final short URL_SELECTED
- A URL string was selected on the Screen
ScreenEvent
public ScreenEvent(java.lang.Object source,
int type,
java.awt.Insets selected,
java.net.URL url)
- Constructs a Screen Event. This is fired from Screen when a URL is selected
or when a cut/paste box is selected, unselected, resized or moved on the Screen.
- Parameters:
source
- The source of the event.type
- The Type of the event.selected
- If the event type is URL_SELECTED, then
this value is set to nullurl
- If the event type is BOX_SELECTED
or BOX_UNSELECTED, this
value is null.
getType
public int getType()
- Returns the event type. The valid values are:
- BOX_SELECTED - A cut/paste box has been selected on the screen.
- BOX_UNSELECTED - A cut/paste box has been unselected on the screen.
- URL_SELECTED - A user has double-clicked on text that represents
a URL.
getInsets
public java.awt.Insets getInsets()
- Returns the selected box coordinates from Screen. The coordinates are returned
in an Insets object, and are mapped as follows:
getInsets().top = y1
getInsets().left = x1
getInsets().bottom = y2
getInsets().right = x2
If the event type is BOX_UNSELECTED or
URL_SELECTED, the coordinates are set to 0.
- See Also:
getType()
getURL
public java.net.URL getURL()
- Returns the URL. If the event type is BOX_SELECTED or
BOX_UNSELECTED, this returns null.