Class Overview
This class represents FocusEvents with a known "cause" - reason why this event happened. It can
be mouse press, traversal, activation, and so on - all causes are described as Cause enum. The
event with the cause can be constructed in two ways - explicitly through constructor of
CausedFocusEvent class or implicitly, by calling appropriate requestFocusXXX method with "cause"
parameter. The default cause is UNKNOWN.
Summary
Nested Classes |
enum |
CausedFocusEvent.Cause |
|
[Expand]
Inherited Fields |
From class
java.awt.AWTEvent
protected
boolean |
consumed |
Controls whether or not the event is sent back down to the peer once the
source has processed it - false means it's sent to the peer; true means
it's not. |
protected
int |
id |
The event's id.@serial |
|
From class
java.util.EventObject
protected
Object |
source |
The object on which the Event initially occurred. |
|
[Expand]
Inherited Methods |
From class
java.awt.event.FocusEvent
|
From class
java.awt.event.ComponentEvent
|
From class
java.awt.AWTEvent
void
|
consume()
Consumes this event, if this event can be consumed.
|
int
|
getID()
Returns the event type.
|
boolean
|
isConsumed()
Returns whether this event has been consumed.
|
String
|
paramString()
Returns a string representing the state of this Event .
|
void
|
setSource(Object newSource)
Retargets an event to a new source.
|
String
|
toString()
Returns a String representation of this object.
|
|
From class
java.util.EventObject
|
From class
java.lang.Object
Object
|
clone()
Creates and returns a copy of this object.
|
boolean
|
equals(Object obj)
Indicates whether some other object is "equal to" this one.
|
void
|
finalize()
Called by the garbage collector on an object when garbage collection
determines that there are no more references to the object.
|
final
Class<?>
|
getClass()
Returns the runtime class of this Object .
|
int
|
hashCode()
Returns a hash code value for the object.
|
final
void
|
notify()
Wakes up a single thread that is waiting on this object's
monitor.
|
final
void
|
notifyAll()
Wakes up all threads that are waiting on this object's monitor.
|
String
|
toString()
Returns a string representation of the object.
|
final
void
|
wait()
Causes the current thread to wait until another thread invokes the
notify() method or the
notifyAll() method for this object.
|
final
void
|
wait(long timeout, int nanos)
Causes the current thread to wait until another thread invokes the
notify() method or the
notifyAll() method for this object, or
some other thread interrupts the current thread, or a certain
amount of real time has elapsed.
|
final
void
|
wait(long timeout)
Causes the current thread to wait until either another thread invokes the
notify() method or the
notifyAll() method for this object, or a
specified amount of time has elapsed.
|
|
Public Constructors
Public Methods
Retargets the original focus event to the new target. If the
original focus event is CausedFocusEvent, it remains such and
cause is copied. Otherwise, new CausedFocusEvent is created,
with cause as RETARGETED.
Returns
- retargeted event, or null if e is null
public
String
toString
()
Returns a String representation of this object.
Returns
- A a String representation of this EventObject.