com.sshtools.terminal
Class ScrollEvent

java.lang.Object
  extended by java.util.EventObject
      extended by com.sshtools.terminal.ScrollEvent
All Implemented Interfaces:
java.io.Serializable

public class ScrollEvent
extends java.util.EventObject

Event fired when an implementation of a VDUScrollBar state changes in some way. For example a Swing implementation using a JScrollBar would fire this event when the user scrolls using the slider UI.

The event will have a type associated with it :-

Author:
$Author: james $
See Also:
Serialized Form

Field Summary
static int VALUE_CHANGED
          The value of the scroll bar has changed.
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
ScrollEvent(java.lang.Object source, int type)
          Create a new ScrollEvent.
ScrollEvent(java.lang.Object source, int type, int value)
          Create a new ScrollEvent.
 
Method Summary
 int getType()
          Get the type of event.
 int getValue()
          Return a value for this event if one is appropriate).
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

VALUE_CHANGED

public static final int VALUE_CHANGED
The value of the scroll bar has changed.

See Also:
Constant Field Values
Constructor Detail

ScrollEvent

public ScrollEvent(java.lang.Object source,
                   int type)
Create a new ScrollEvent. Type type will be one of

Parameters:
source - source of event
type - event type

ScrollEvent

public ScrollEvent(java.lang.Object source,
                   int type,
                   int value)

Create a new ScrollEvent. Type type will be one of

Some event types may value of value associated with them which can also be specified using this constructor

Parameters:
source - source of event
type - event type
value - value for appropriate event types
Method Detail

getType

public int getType()
Get the type of event. This will be one of:-

Returns:
type

getValue

public int getValue()
Return a value for this event if one is appropriate). For example,an Integer object specifying the amount the scroll bar has changed if the type is VALUE_CHANGED.

Returns:
event value


Copyright © 2003-2004 3SP LTD. All Rights Reserved.