Removed po directory from Makefile.am for now.
[platform/core/uifw/at-spi2-atk.git] / cspi / spi-listener.h
1 #ifndef _SPI_LISTENER_H_
2 #define _SPI_LISTENER_H_
3
4 #include <cspi/spi-impl.h>
5
6 G_BEGIN_DECLS
7
8 /*
9  * Structure used to encapsulate event information
10  */
11 typedef struct {
12   const char  *type;
13   Accessible  *source;
14   long         detail1;
15   long         detail2;
16 } AccessibleEvent;
17
18 typedef enum {
19   SPI_KEY_PRESSED  = 1<<0,
20   SPI_KEY_RELEASED = 1<<1
21 } AccessibleKeyEventType;
22
23
24 typedef struct {
25   long                   keyID;
26   short                  keycode;
27   long                   timestamp;
28   AccessibleKeyEventType type;
29   unsigned short         modifiers;
30 } AccessibleKeystroke;
31
32 /*
33  * Function prototype typedefs for Event Listener Callbacks.
34  * (see libspi/accessibleeventlistener.h for definition of SpiVoidEventListenerCB).
35  *
36  * usage: signatures should be
37  * void (*AccessibleEventListenerCB) (AccessibleEvent *event);
38  *
39  * SPIBoolean (*AccessibleKeystrokeListenerCB) (AccessibleKeystrokeEvent *Event);
40  */
41 typedef void       (*AccessibleEventListenerCB)     (AccessibleEvent     *event,
42                                                      void                *user_data);
43 typedef SPIBoolean (*AccessibleKeystrokeListenerCB) (AccessibleKeystroke *stroke,
44                                                      void                *user_data);
45
46 G_END_DECLS
47
48 #endif