1 | /* gok-spy-priv.h |
---|
2 | * |
---|
3 | * Copyright 2001,2002 Sun Microsystems, Inc., |
---|
4 | * Copyright 2001,2002 University Of Toronto |
---|
5 | * |
---|
6 | * This library is free software; you can redistribute it and/or |
---|
7 | * modify it under the terms of the GNU Library General Public |
---|
8 | * License as published by the Free Software Foundation; either |
---|
9 | * version 2 of the License, or (at your option) any later version. |
---|
10 | * |
---|
11 | * This library is distributed in the hope that it will be useful, |
---|
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
---|
14 | * Library General Public License for more details. |
---|
15 | * |
---|
16 | * You should have received a copy of the GNU Library General Public |
---|
17 | * License along with this library; if not, write to the |
---|
18 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
---|
19 | * Boston, MA 02111-1307, USA. |
---|
20 | */ |
---|
21 | |
---|
22 | #ifndef __GOK_SPY_PRIV_H__ |
---|
23 | #define __GOK_SPY_PRIV_H__ |
---|
24 | |
---|
25 | #ifdef __cplusplus |
---|
26 | extern "C" { |
---|
27 | #endif /* __cplusplus */ |
---|
28 | |
---|
29 | #include <cspi/spi.h> |
---|
30 | #include <libspi/Accessibility.h> |
---|
31 | #include <libspi/accessible.h> |
---|
32 | #include <libspi/application.h> |
---|
33 | |
---|
34 | enum gokevents { |
---|
35 | GOKSPY_FOCUS_EVENT, |
---|
36 | GOKSPY_DEFUNCT_EVENT, |
---|
37 | GOKSPY_WINDOW_ACTIVATE_EVENT, |
---|
38 | GOKSPY_WINDOW_DEACTIVATE_EVENT, |
---|
39 | GOKSPY_STATE_EVENT, |
---|
40 | GOKSPY_CONTAINER_EVENT, |
---|
41 | GOKSPY_KEYMAP_EVENT |
---|
42 | }; |
---|
43 | |
---|
44 | typedef union |
---|
45 | { |
---|
46 | guint value; |
---|
47 | struct { |
---|
48 | guint is_link:1; |
---|
49 | guint is_ui:1; |
---|
50 | guint is_menu:1; |
---|
51 | guint has_context_menu:1; |
---|
52 | guint is_toolbar_item:1; |
---|
53 | guint inside_html_container:1; |
---|
54 | } data; |
---|
55 | } AccessibleNodeFlags; |
---|
56 | |
---|
57 | /* this structure used in the creation of a linked list of Accessible*, char* (name) pairs */ |
---|
58 | typedef struct AccessibleNode |
---|
59 | { |
---|
60 | Accessible* paccessible; |
---|
61 | AccessibleNodeFlags flags; |
---|
62 | guint link; |
---|
63 | char* pname; |
---|
64 | } AccessibleNode; |
---|
65 | |
---|
66 | /* this structure intended for use with a GQueue */ |
---|
67 | typedef struct EventNode |
---|
68 | { |
---|
69 | const AccessibleEvent *event; |
---|
70 | gint type; /* easier than dealing with string data */ |
---|
71 | } EventNode; |
---|
72 | |
---|
73 | /* callback types */ |
---|
74 | typedef void (*ListChangeListenerCB) (AccessibleNode* plist); |
---|
75 | typedef void (*AccessibleChangeListenerCB) (Accessible* paccessible); |
---|
76 | typedef void (*MouseButtonListenerCB) (gint mouseButton, gint state, long x, long y); |
---|
77 | typedef void ListChangeListener; |
---|
78 | typedef void AccessibleChangeListener; |
---|
79 | typedef void MouseButtonListener; |
---|
80 | |
---|
81 | #ifdef __cplusplus |
---|
82 | } |
---|
83 | #endif /* __cplusplus */ |
---|
84 | |
---|
85 | #endif /* #ifndef__GOK_SPY_PRIV_H__ */ |
---|