-
Notifications
You must be signed in to change notification settings - Fork 2
/
commonqt.h
103 lines (82 loc) · 2.95 KB
/
commonqt.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
#ifdef __cplusplus
extern "C" {
#endif
#ifdef WIN32
# define EXPORT __declspec(dllexport)
#else
# define EXPORT
#endif
class DynamicBinding;
class Binding;
typedef struct SmokeData {
const char *name;
void *classes;
short numClasses;
void *methods;
short numMethods;
void *methodMaps;
short numMethodMaps;
void *methodNames;
short numMethodNames;
void *types;
short numTypes;
short *inheritanceList;
short *argumentList;
short *ambiguousMethodList;
void *castFn;
void *binding;
} SmokeData;
EXPORT void sw_init();
EXPORT void sw_smoke(Smoke *, SmokeData*, void *, void *);
EXPORT void sw_override(DynamicBinding*, short, short);
EXPORT void* sw_make_dynamic_binding(Smoke*, QMetaObject*, short, short,
void*, void*, void*);
EXPORT void* sw_make_qvector_uint(unsigned int *, int);
EXPORT void sw_delete_qvector_uint(void *);
EXPORT void* sw_make_qbytearray(char *);
EXPORT void sw_delete_qbytearray(void *q);
EXPORT void* sw_make_qstring(char *);
EXPORT void sw_delete_qstring(void *);
EXPORT void* sw_make_metaobject(void *);
EXPORT void* sw_make_metaobject_builder(char *, void *);
EXPORT void sw_delete_metaobject_builder(void *);
EXPORT void sw_add_classinfo_to_metaobject_builder(void *, char *, char *);
EXPORT void sw_add_method_to_metaobject_builder(void *, char *);
EXPORT void sw_add_signal_to_metaobject_builder(void *, char *);
EXPORT void sw_add_slot_to_metaobject_builder(void *, char *);
EXPORT void sw_delete(void *p);
EXPORT void* sw_qstring_to_utf8(void* s);
EXPORT const void* sw_qstring_to_utf16(void*);
EXPORT int sw_windows_version();
EXPORT void sw_find_class(char *, Smoke **, short *);
EXPORT void sw_id_instance_class(void *, Smoke **, short *);
EXPORT short sw_find_name(Smoke *, char *);
EXPORT short sw_id_method(Smoke *, short, short);
EXPORT short sw_id_type(Smoke *, char *);
EXPORT short sw_id_class(Smoke *, char *, bool);
EXPORT void* sw_qstringlist_new();
EXPORT void sw_qstringlist_delete(void*);
EXPORT void sw_qstringlist_append(void*, char*);
EXPORT int sw_qstringlist_size(void*);
EXPORT const void* sw_qstringlist_at(void*, int);
EXPORT void* sw_qlist_void_new(void);
EXPORT int sw_qlist_void_size(void*);
EXPORT void sw_qlist_void_delete(void*);
EXPORT const void* sw_qlist_void_at(void*, int);
EXPORT void sw_qlist_void_append(void*, void*);
#define DECLARE_QLIST_SCALAR_MARSHALLER(NAME) \
EXPORT void* sw_qlist_##NAME##_new(); \
EXPORT int sw_qlist_##NAME##_size(void *ptr); \
EXPORT void sw_qlist_##NAME##_delete(void *ptr); \
EXPORT const void* sw_qlist_##NAME##_at(void *ptr, int index); \
EXPORT void sw_qlist_##NAME##_append(void *ptr, void *whatptr);
DECLARE_QLIST_SCALAR_MARSHALLER(int)
DECLARE_QLIST_SCALAR_MARSHALLER(papersize)
DECLARE_QLIST_SCALAR_MARSHALLER(qvariant)
DECLARE_QLIST_SCALAR_MARSHALLER(qbytearray)
DECLARE_QLIST_SCALAR_MARSHALLER(qmodelindex)
DECLARE_QLIST_SCALAR_MARSHALLER(qkeysequence)
DECLARE_QLIST_SCALAR_MARSHALLER(extraselection)
#ifdef __cplusplus
}
#endif