The SSR is implemented with the following classes and interfaces:
- This is the main class of the tool. It is responsible for setting up and managing the GUI
- The connection task is a thread that waits in the background for a OpenOffice.org application to start. As soon as there is one, it connects to it and initiates the registration at all of its accessible objects.
- Each object of this class creates one thread that adds or removes the event listener at all accessible objects in one tree, with one tree per application window. This is done in separate threads so that the normal operation of the tool is not blocked while registering to complex applications with many objects.
- This is a singleton class. Its only instance is registered as listener at all accessible objects. It runs in its own thread and delivers the received events eventually to the actual event handler. This de-coupling between event reception and event handling is necessary to avoid deadlocks. Soon this will become obsolete.
- There is usually only one object of this class. It prints log messages for all the events it receives and provides special handling some of events:
- Top window events denoting new or removed application windows are not accessibility events in a strict sense. They have to be listened to, however, to add or remove the event listener to the accessibility objects that correspond to these windows.
- State events that inform the listener of a set or reset FOCUSED state. This is the most important event for the SSR in order to keep track of the currently focused object.
- Events that signal a change of the geometric property of the currently focused object trigger a redisplay of the two windows that display that object. This ensures that you always see the current position of the object.
- This widget displays textual information about the focused object as described previously.
- This widget displays graphical information about the focused object as described previously.
- This is the interface supported by the two display widgets. It defines how the event handler tells the displays about focus and geometry changes. You can add other displays as well by adding a widget that implements this interface to the event handler and to the GUI.
- The message area at the bottom is a simple text widget that scrolls its content so that the last line that contains the most recent message is always visible.
- This is a useful helper class that converts numerical IDs into names, roles, events, or states.
Parts of some of these classes will be explained at later points in this text. Others, like the
ConnectionTask class, are a mere technicality with respect to the accessibility API and will not be detailed any further.
|Content on this page is licensed under the Public Documentation License (PDL).|