All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.sun.java.accessibility.EventQueueMonitor

java.lang.Object
   |
   +----java.awt.EventQueue
           |
           +----com.sun.java.accessibility.EventQueueMonitor

public class EventQueueMonitor
extends EventQueue

The EventQueueMonitor is an EventQueue subclass that provides key core functionality for Assistive Technologies (and other system-level technologies that need some of the same things that Assistive Technology needs). Specifically, it provides the following things:

This class is meant to be automatically loaded by the Toolkit when it starts up. In order for this to happen, this class needs to be in the CLASSPATH environment variable and the following line needs to be in the awt.properties file:

 AWT.EventQueueClass=com.sun.java.accessibility.EventQueueMonitor
 

This class also looks for the AWT.AutoLoadClasses property in the awt.properties file. This is a comma-separated list of classes that represent assistive technologies that should run in the same Java Virtual Machine as the application. If this property exists, this class will load each class in the list and create an instance of it in a separate thread.

This class is commonly used with one or two other classes: AWTEventMonitor, and SwingEventMonitor, which track all events generated by AWT obects and Swing objects resptively. To use either of those classes, they should be specified via the AWT.AutoLoadClasses property, as described above.

NOTE: This is a preliminary draft. The methods and name may change in future beta releases.


Constructor Index

 o EventQueueMonitor()

Method Index

 o addTopLevelWindowListener(TopLevelWindowListener)
Adds the specified listener to receive events when they occur.
 o getAccessibleAt(Point)
Obtain the Accessible object at the given point on the Screen.
 o getCurrentMousePosition()
Return the last recorded position of the mouse in screen coordinates.
 o getTopLevelWindows()
Return the list of top level Windows in use in the Java Virtual Machine.
 o getTopLevelWindowWithFocus()
Return the top level Window that currently has focus.
 o postEvent(AWTEvent)
Post a 1.1-style event to the EventQueue.
 o removeTopLevelWindowListener(TopLevelWindowListener)
Removes the specified listener so it no longer receives events when they occur.

Constructors

 o EventQueueMonitor
 public EventQueueMonitor()

Methods

 o getAccessibleAt
 public static Accessible getAccessibleAt(Point p)
Obtain the Accessible object at the given point on the Screen. The return value may be null if an Accessible object cannot be found at the particular point.

 o addTopLevelWindowListener
 public static void addTopLevelWindowListener(TopLevelWindowListener l)
Adds the specified listener to receive events when they occur.

Parameters:
l - the listener to add
 o removeTopLevelWindowListener
 public static void removeTopLevelWindowListener(TopLevelWindowListener l)
Removes the specified listener so it no longer receives events when they occur.

Parameters:
l - the listener to remove
 o getCurrentMousePosition
 public static Point getCurrentMousePosition()
Return the last recorded position of the mouse in screen coordinates.

Returns:
the last recorded position of the mouse in screen coordinates
 o getTopLevelWindows
 public static Window[] getTopLevelWindows()
Return the list of top level Windows in use in the Java Virtual Machine.

Returns:
an array of top level Windows in use in the Java Virtual Machine
 o getTopLevelWindowWithFocus
 public static Window getTopLevelWindowWithFocus()
Return the top level Window that currently has focus.

Returns:
the top level Window that currently has focus
 o postEvent
 public void postEvent(AWTEvent theEvent)
Post a 1.1-style event to the EventQueue.

Parameters:
theEvent - the AWTEvent
Overrides:
postEvent in class EventQueue

All Packages  Class Hierarchy  This Package  Previous  Next  Index