com.threerings.opengl.gui.event
Class Event

java.lang.Object
  extended by java.util.EventObject
      extended by com.threerings.opengl.gui.event.Event
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
ChangeEvent, FocusEvent, InputEvent, TextEvent

public class Event
extends EventObject

The base event class for all events.

See Also:
Serialized Form

Field Summary
protected  boolean _consumed
          Whether or not the event has been flagged as "consumed."
protected  long _when
           
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
protected Event(Object source, long when)
           
 
Method Summary
 void consume()
          Flags this event as consumed.
 void dispatch(ComponentListener listener)
          Instructs this event to notify the supplied listener if they implement an interface appropriate to this event.
 long getWhen()
          Returns the time at which this event was generated or -1 if this event was not a result of a user action with an associated timestamp.
 boolean isConsumed()
          Checks whether the event has been flagged as consumed.
 boolean propagateUpHierarchy()
          Returns true if this event should be propagated up the interface hierarchy (input events) or false if it should be considered processed once it is dispatched on its originating component (derivative events like action or text events).
 String toString()
          Generates a string representation of this instance.
protected  void toString(StringBuilder buf)
           
 
Methods inherited from class java.util.EventObject
getSource
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_when

protected long _when

_consumed

protected boolean _consumed
Whether or not the event has been flagged as "consumed."

Constructor Detail

Event

protected Event(Object source,
                long when)
Method Detail

getWhen

public long getWhen()
Returns the time at which this event was generated or -1 if this event was not a result of a user action with an associated timestamp.


isConsumed

public boolean isConsumed()
Checks whether the event has been flagged as consumed.


consume

public void consume()
Flags this event as consumed.


toString

public String toString()
Generates a string representation of this instance.

Overrides:
toString in class EventObject

dispatch

public void dispatch(ComponentListener listener)
Instructs this event to notify the supplied listener if they implement an interface appropriate to this event.


propagateUpHierarchy

public boolean propagateUpHierarchy()
Returns true if this event should be propagated up the interface hierarchy (input events) or false if it should be considered processed once it is dispatched on its originating component (derivative events like action or text events).


toString

protected void toString(StringBuilder buf)