+typedef struct _AccessibleRoleSet
+{
+ int len;
+ AccessibleRole *roles;
+} AccessibleRoleSet;
+
+
+
+/* Basic SPI initialization and event loop function prototypes */
+
+int SPI_init (void);
+void SPI_event_main (void);
+void SPI_event_quit (void);
+SPIBoolean SPI_eventIsReady (void);
+AccessibleEvent *SPI_nextEvent (SPIBoolean waitForEvent);
+int SPI_exit (void);
+
+/* Event Listener creation and support. */
+
+void SPI_freeAccessibleKeySet (
+ AccessibleKeySet *keyset);
+AccessibleKeySet * SPI_createAccessibleKeySet (
+ int len,
+ const char *keysyms,
+ short *keycodes,
+ const char **keystrings);
+AccessibleEventListener * SPI_createAccessibleEventListener (
+ AccessibleEventListenerCB callback,
+ void *user_data);
+SPIBoolean AccessibleEventListener_addCallback (
+ AccessibleEventListener *listener,
+ AccessibleEventListenerCB callback,
+ void *user_data);
+SPIBoolean AccessibleEventListener_removeCallback (
+ AccessibleEventListener *listener,
+ AccessibleEventListenerCB callback);
+void AccessibleEventListener_unref (
+ AccessibleEventListener *listener);
+
+/* Device Event Listener creation and support. */
+
+/* First four are deprecated in favor of the last four; really just a re-name */
+
+AccessibleKeystrokeListener * SPI_createAccessibleKeystrokeListener (
+ AccessibleKeystrokeListenerCB callback,
+ void *user_data);
+SPIBoolean AccessibleKeystrokeListener_addCallback (
+ AccessibleKeystrokeListener *listener,
+ AccessibleKeystrokeListenerCB callback,
+ void *user_data);
+SPIBoolean AccessibleKeystrokeListener_removeCallback (
+ AccessibleKeystrokeListener *listener,
+ AccessibleKeystrokeListenerCB callback);
+void AccessibleKeystrokeListener_unref (
+ AccessibleKeystrokeListener *listener);
+
+AccessibleDeviceListener * SPI_createAccessibleDeviceListener (
+ AccessibleDeviceListenerCB callback,
+ void *user_data);
+SPIBoolean AccessibleDeviceListener_addCallback (
+ AccessibleDeviceListener *listener,
+ AccessibleDeviceListenerCB callback,
+ void *user_data);
+SPIBoolean AccessibleDeviceListener_removeCallback (
+ AccessibleDeviceListener *listener,
+ AccessibleDeviceListenerCB callback);
+void AccessibleDeviceListener_unref (
+ AccessibleDeviceListener *listener);
+
+/* Global functions serviced by the registry */
+
+SPIBoolean SPI_registerGlobalEventListener (
+ AccessibleEventListener *listener,
+ const char *eventType);
+SPIBoolean SPI_deregisterGlobalEventListener (
+ AccessibleEventListener *listener,
+ const char *eventType);
+SPIBoolean SPI_deregisterGlobalEventListenerAll (
+ AccessibleEventListener *listener);
+SPIBoolean SPI_registerAccessibleKeystrokeListener (
+ AccessibleKeystrokeListener *listener,
+ AccessibleKeySet *keys,
+ AccessibleKeyMaskType modmask,
+ AccessibleKeyEventMask eventmask,
+ AccessibleKeyListenerSyncType sync_type);
+SPIBoolean SPI_deregisterAccessibleKeystrokeListener (
+ AccessibleKeystrokeListener *listener,
+ AccessibleKeyMaskType modmask);
+
+SPIBoolean SPI_registerDeviceEventListener (
+ AccessibleDeviceListener *listener,
+ AccessibleDeviceEventMask eventmask,
+ void *filter);
+SPIBoolean SPI_deregisterDeviceEventListener (
+ AccessibleDeviceListener *listener,
+ void *filter);
+
+int SPI_getDesktopCount (void);
+Accessible *SPI_getDesktop (int i);
+int SPI_getDesktopList (Accessible ***desktop_list);
+void SPI_freeDesktopList (Accessible **desktop_list);
+
+SPIBoolean SPI_generateKeyboardEvent (long int keyval,
+ char *keystring,
+ AccessibleKeySynthType synth_type);
+
+SPIBoolean SPI_generateMouseEvent (long int x, long int y, char *name);
+
+/* Accessible function prototypes */
+
+void Accessible_ref (Accessible *obj);
+void Accessible_unref (Accessible *obj);
+char * Accessible_getName (Accessible *obj);
+char * Accessible_getDescription (Accessible *obj);
+Accessible * Accessible_getParent (Accessible *obj);
+long Accessible_getChildCount (Accessible *obj);
+Accessible * Accessible_getChildAtIndex (Accessible *obj,
+ long int childIndex);
+long Accessible_getIndexInParent (Accessible *obj);
+AccessibleRelation **Accessible_getRelationSet (Accessible *obj);
+AccessibleRole Accessible_getRole (Accessible *obj);
+char * Accessible_getRoleName (Accessible *obj);
+char * Accessible_getLocalizedRoleName (Accessible *obj);
+AccessibleStateSet * Accessible_getStateSet (Accessible *obj);
+AccessibleAttributeSet *Accessible_getAttributes (Accessible *obj);
+AccessibleApplication *Accessible_getHostApplication (Accessible *obj);