Re-work the bonobo code.
[platform/core/uifw/at-spi2-atk.git] / cspi / bonobo / cspi-bonobo-listener.h
1 #ifndef __SPI_LISTENER_IMPL_H__
2 #define __SPI_LISTENER_IMP_H__
3
4 #include <libspi/eventlistener.h>
5 #include <libspi/keystrokelistener.h>
6 #include <cspi/spi-impl.h>
7 #include <cspi/spi-listener.h>
8
9 G_BEGIN_DECLS
10
11 #define CSPI_EVENT_LISTENER_TYPE        (cspi_event_listener_get_type ())
12 #define CSPI_EVENT_LISTENER(o)          (G_TYPE_CHECK_INSTANCE_CAST ((o), CSPI_EVENT_LISTENER_TYPE, CSpiEventListener))
13 #define CSPI_EVENT_LISTENER_CLASS(k)    (G_TYPE_CHECK_CLASS_CAST((k), CSPI_EVENT_LISTENER_TYPE, CSpiEventListenerClass))
14 #define CSPI_IS_EVENT_LISTENER(o)       (G_TYPE_CHECK_INSTANCE_TYPE ((o), CSPI_EVENT_LISTENER_TYPE))
15 #define CSPI_IS_EVENT_LISTENER_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), CSPI_EVENT_LISTENER_TYPE))
16
17 typedef struct {
18         SpiEventListener parent;
19         GList           *callbacks;
20 } CSpiEventListener;
21 typedef SpiEventListenerClass CSpiEventListenerClass;
22
23 GType cspi_event_listener_get_type (void);
24
25 #define CSPI_KEYSTROKE_LISTENER_TYPE        (cspi_keystroke_listener_get_type ())
26 #define CSPI_KEYSTROKE_LISTENER(o)          (G_TYPE_CHECK_INSTANCE_CAST ((o), CSPI_KEYSTROKE_LISTENER_TYPE, CSpiKeystrokeListener))
27 #define CSPI_KEYSTROKE_LISTENER_CLASS(k)    (G_TYPE_CHECK_CLASS_CAST((k), CSPI_KEYSTROKE_LISTENER_TYPE, CSpiKeystrokeListenerClass))
28 #define CSPI_IS_KEYSTROKE_LISTENER(o)       (G_TYPE_CHECK_INSTANCE_TYPE ((o), CSPI_KEYSTROKE_LISTENER_TYPE))
29 #define CSPI_IS_KEYSTROKE_LISTENER_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), CSPI_KEYSTROKE_LISTENER_TYPE))
30
31 typedef struct {
32         SpiKeystrokeListener parent;
33         GList               *callbacks;
34 } CSpiKeystrokeListener;
35 typedef SpiKeystrokeListenerClass CSpiKeystrokeListenerClass;
36
37 GType cspi_keystroke_listener_get_type (void);
38
39 G_END_DECLS
40
41 #endif /* __SPI_LISTENER_IMPL_H__ */