|  |  |  | libatspi Reference Manual |  | 
|---|---|---|---|---|
| Top | Description | Object Hierarchy | ||||
gboolean (*AtspiDeviceListenerCB) (const AtspiDeviceEvent *stroke,void *user_data); gboolean (*AtspiDeviceListenerSimpleCB) (const AtspiDeviceEvent *stroke); AtspiDeviceListener; AtspiDeviceListenerClass; AtspiDeviceListener * atspi_device_listener_new (AtspiDeviceListenerCB callback,GDestroyNotify callback_destroyed,void *user_data); AtspiDeviceListener * atspi_device_listener_new_simple (AtspiDeviceListenerSimpleCB callback,GDestroyNotify callback_destroyed); void atspi_device_listener_add_callback (AtspiDeviceListener *listener,AtspiDeviceListenerCB callback,GDestroyNotify callback_destroyed,void *user_data); void atspi_device_listener_remove_callback (AtspiDeviceListener *listener,AtspiDeviceListenerCB callback);
gboolean (*AtspiDeviceListenerCB) (const AtspiDeviceEvent *stroke,void *user_data);
A callback function prototype via which clients receive device event notifications.
| 
 | The AtspiDeviceEvent for which notification is being received.. transfer full. | 
| 
 | Data which is passed to the client each time this callback is notified. | 
| Returns : | TRUEif the client wishes to consume/preempt the event, preventing it from being
relayed to the currently focussed application,FALSEif the event delivery should proceed as normal. | 
gboolean            (*AtspiDeviceListenerSimpleCB)      (const AtspiDeviceEvent *stroke);
Like AtspiDeviceListenerCB but with no user data.
| 
 | The AtspiDeviceEvent for which notification is being received.. transfer full. | 
| Returns : | TRUEif the client wishes to consume/preempt the event, preventing it from being
relayed to the currently focussed application,FALSEif the event delivery should proceed as normal. | 
typedef struct {
  GObjectClass parent_class;
  gboolean (*device_event) (AtspiDeviceListener *, const AtspiDeviceEvent *);
} AtspiDeviceListenerClass;
AtspiDeviceListener * atspi_device_listener_new (AtspiDeviceListenerCB callback,GDestroyNotify callback_destroyed,void *user_data);
Create a new AtspiDeviceListener with a specified callback function.
| 
 | an AtspiDeviceListenerCB callback function, or NULL.. scope notify | 
| 
 | A GDestroyNotify called when the listener is freed and data associated with the callback should be freed. Can be NULL. | 
| 
 | a pointer to data which will be passed to the callback when invoked.. closure | 
| Returns : | a pointer to a newly-created AtspiDeviceListener. | 
AtspiDeviceListener * atspi_device_listener_new_simple (AtspiDeviceListenerSimpleCB callback,GDestroyNotify callback_destroyed);
Create a new AtspiDeviceListener with a specified callback function. Like atspi_device_listener_new, but callback takes no user data.
| 
 | an AtspiDeviceListenerCB callback function, or NULL.. scope notify | 
| 
 | A GDestroyNotify called when the listener is freed and data associated with the callback should be freed. Can be NULL. | 
| Returns : | a pointer to a newly-created AtspiDeviceListener. | 
void atspi_device_listener_add_callback (AtspiDeviceListener *listener,AtspiDeviceListenerCB callback,GDestroyNotify callback_destroyed,void *user_data);
Add an in-process callback function to an existing AtspiDeviceListener.
| 
 | the AtspiDeviceListener instance to modify. | 
| 
 | an AtspiDeviceListenerCB function pointer.. scope notify | 
| 
 | A GDestroyNotify called when the listener is freed and data associated with the callback should be freed. Can be NULL. | 
| 
 | a pointer to data which will be passed to the callback when invoked.. closure | 
void atspi_device_listener_remove_callback (AtspiDeviceListener *listener,AtspiDeviceListenerCB callback);
Remove an in-process callback function from an existing AtspiDeviceListener.
| 
 | the AtspiDeviceListener instance to modify. | 
| 
 | an AtspiDeviceListenerCB function pointer.. scope call |