]>
Commit | Line | Data |
---|---|---|
d56cebe7 RD |
1 | /* |
2 | * FILE : contrib/xrc/xrc.cpp | |
3 | * | |
4 | * This file was automatically generated by : | |
5 | * Simplified Wrapper and Interface Generator (SWIG) | |
6 | * Version 1.1 (Build 883) | |
7 | * | |
8 | * Portions Copyright (c) 1995-1998 | |
9 | * The University of Utah and The Regents of the University of California. | |
10 | * Permission is granted to distribute this file in any manner provided | |
11 | * this notice remains intact. | |
12 | * | |
13 | * Do not make changes to this file--changes will be lost! | |
14 | * | |
15 | */ | |
16 | ||
17 | ||
18 | #define SWIGCODE | |
19 | /* Implementation : PYTHON */ | |
20 | ||
21 | #define SWIGPYTHON | |
22 | #include <string.h> | |
23 | #include <stdlib.h> | |
24 | /* Definitions for Windows/Unix exporting */ | |
25 | #if defined(__WIN32__) | |
26 | # if defined(_MSC_VER) | |
27 | # define SWIGEXPORT(a) __declspec(dllexport) a | |
28 | # else | |
29 | # if defined(__BORLANDC__) | |
30 | # define SWIGEXPORT(a) a _export | |
31 | # else | |
32 | # define SWIGEXPORT(a) a | |
33 | # endif | |
34 | # endif | |
35 | #else | |
36 | # define SWIGEXPORT(a) a | |
37 | #endif | |
38 | ||
39 | #include "Python.h" | |
40 | ||
41 | #ifdef __cplusplus | |
42 | extern "C" { | |
43 | #endif | |
44 | ||
45 | extern void SWIG_MakePtr(char *, void *, char *); | |
46 | extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *)); | |
47 | extern char *SWIG_GetPtr(char *, void **, char *); | |
48 | extern char *SWIG_GetPtrObj(PyObject *, void **, char *); | |
49 | extern void SWIG_addvarlink(PyObject *, char *, PyObject *(*)(void), int (*)(PyObject *)); | |
50 | extern PyObject *SWIG_newvarlink(void); | |
51 | #ifdef __cplusplus | |
52 | } | |
53 | #endif | |
54 | #define SWIG_init initxrcc | |
55 | ||
56 | #define SWIG_name "xrcc" | |
57 | ||
6e2129f9 | 58 | #include "wxPython.h" |
d56cebe7 RD |
59 | #include "wx/xrc/xmlres.h" |
60 | ||
61 | ||
62 | static PyObject* t_output_helper(PyObject* target, PyObject* o) { | |
63 | PyObject* o2; | |
64 | PyObject* o3; | |
65 | ||
66 | if (!target) { | |
67 | target = o; | |
68 | } else if (target == Py_None) { | |
69 | Py_DECREF(Py_None); | |
70 | target = o; | |
71 | } else { | |
72 | if (!PyTuple_Check(target)) { | |
73 | o2 = target; | |
74 | target = PyTuple_New(1); | |
75 | PyTuple_SetItem(target, 0, o2); | |
76 | } | |
77 | o3 = PyTuple_New(1); | |
78 | PyTuple_SetItem(o3, 0, o); | |
79 | ||
80 | o2 = target; | |
81 | target = PySequence_Concat(o2, o3); | |
82 | Py_DECREF(o2); | |
83 | Py_DECREF(o3); | |
84 | } | |
85 | return target; | |
86 | } | |
d56cebe7 RD |
87 | #ifdef __cplusplus |
88 | extern "C" { | |
89 | #endif | |
d56cebe7 RD |
90 | static void *SwigwxXmlResourceTowxObject(void *ptr) { |
91 | wxXmlResource *src; | |
92 | wxObject *dest; | |
93 | src = (wxXmlResource *) ptr; | |
94 | dest = (wxObject *) src; | |
95 | return (void *) dest; | |
96 | } | |
97 | ||
98 | #define new_wxXmlResourceEmpty(_swigarg0) (new wxXmlResource(_swigarg0)) | |
99 | static PyObject *_wrap_new_wxXmlResourceEmpty(PyObject *self, PyObject *args, PyObject *kwargs) { | |
100 | PyObject * _resultobj; | |
101 | wxXmlResource * _result; | |
b5a5d647 RD |
102 | int _arg0 = (int ) (wxXRC_USE_LOCALE); |
103 | char *_kwnames[] = { "flags", NULL }; | |
d56cebe7 RD |
104 | char _ptemp[128]; |
105 | ||
106 | self = self; | |
b5a5d647 | 107 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|i:new_wxXmlResourceEmpty",_kwnames,&_arg0)) |
d56cebe7 | 108 | return NULL; |
d56cebe7 | 109 | { |
4268f798 | 110 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 111 | _result = (wxXmlResource *)new_wxXmlResourceEmpty(_arg0); |
d56cebe7 | 112 | |
4268f798 RD |
113 | wxPyEndAllowThreads(__tstate); |
114 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
115 | } if (_result) { |
116 | SWIG_MakePtr(_ptemp, (char *) _result,"_wxXmlResource_p"); | |
117 | _resultobj = Py_BuildValue("s",_ptemp); | |
118 | } else { | |
119 | Py_INCREF(Py_None); | |
120 | _resultobj = Py_None; | |
121 | } | |
122 | return _resultobj; | |
123 | } | |
124 | ||
b5a5d647 RD |
125 | static wxXmlResource *new_wxXmlResource(const wxString *filemask,int flags) { |
126 | wxXmlResource* res = new wxXmlResource(*filemask, flags); | |
d56cebe7 RD |
127 | res->InitAllHandlers(); |
128 | return res; | |
129 | } | |
130 | ||
131 | static PyObject *_wrap_new_wxXmlResource(PyObject *self, PyObject *args, PyObject *kwargs) { | |
132 | PyObject * _resultobj; | |
133 | wxXmlResource * _result; | |
134 | wxString * _arg0; | |
b5a5d647 | 135 | int _arg1 = (int ) (wxXRC_USE_LOCALE); |
d56cebe7 | 136 | PyObject * _obj0 = 0; |
b5a5d647 | 137 | char *_kwnames[] = { "filemask","flags", NULL }; |
d56cebe7 RD |
138 | char _ptemp[128]; |
139 | ||
140 | self = self; | |
b5a5d647 | 141 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:new_wxXmlResource",_kwnames,&_obj0,&_arg1)) |
d56cebe7 RD |
142 | return NULL; |
143 | { | |
c8bc7bb8 RD |
144 | _arg0 = wxString_in_helper(_obj0); |
145 | if (_arg0 == NULL) | |
d56cebe7 | 146 | return NULL; |
d56cebe7 | 147 | } |
d56cebe7 | 148 | { |
4268f798 | 149 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 150 | _result = (wxXmlResource *)new_wxXmlResource(_arg0,_arg1); |
d56cebe7 | 151 | |
4268f798 RD |
152 | wxPyEndAllowThreads(__tstate); |
153 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
154 | } if (_result) { |
155 | SWIG_MakePtr(_ptemp, (char *) _result,"_wxXmlResource_p"); | |
156 | _resultobj = Py_BuildValue("s",_ptemp); | |
157 | } else { | |
158 | Py_INCREF(Py_None); | |
159 | _resultobj = Py_None; | |
160 | } | |
161 | { | |
162 | if (_obj0) | |
163 | delete _arg0; | |
164 | } | |
165 | return _resultobj; | |
166 | } | |
167 | ||
168 | #define delete_wxXmlResource(_swigobj) (delete _swigobj) | |
169 | static PyObject *_wrap_delete_wxXmlResource(PyObject *self, PyObject *args, PyObject *kwargs) { | |
170 | PyObject * _resultobj; | |
171 | wxXmlResource * _arg0; | |
172 | PyObject * _argo0 = 0; | |
173 | char *_kwnames[] = { "self", NULL }; | |
174 | ||
175 | self = self; | |
176 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxXmlResource",_kwnames,&_argo0)) | |
177 | return NULL; | |
178 | if (_argo0) { | |
179 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
180 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
181 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of delete_wxXmlResource. Expected _wxXmlResource_p."); | |
182 | return NULL; | |
183 | } | |
184 | } | |
185 | { | |
4268f798 | 186 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 187 | delete_wxXmlResource(_arg0); |
d56cebe7 | 188 | |
4268f798 RD |
189 | wxPyEndAllowThreads(__tstate); |
190 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
191 | } Py_INCREF(Py_None); |
192 | _resultobj = Py_None; | |
193 | return _resultobj; | |
194 | } | |
195 | ||
196 | #define wxXmlResource_Load(_swigobj,_swigarg0) (_swigobj->Load(_swigarg0)) | |
197 | static PyObject *_wrap_wxXmlResource_Load(PyObject *self, PyObject *args, PyObject *kwargs) { | |
198 | PyObject * _resultobj; | |
199 | bool _result; | |
200 | wxXmlResource * _arg0; | |
201 | wxString * _arg1; | |
202 | PyObject * _argo0 = 0; | |
203 | PyObject * _obj1 = 0; | |
204 | char *_kwnames[] = { "self","filemask", NULL }; | |
205 | ||
206 | self = self; | |
207 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_Load",_kwnames,&_argo0,&_obj1)) | |
208 | return NULL; | |
209 | if (_argo0) { | |
210 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
211 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
212 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_Load. Expected _wxXmlResource_p."); | |
213 | return NULL; | |
214 | } | |
215 | } | |
216 | { | |
c8bc7bb8 RD |
217 | _arg1 = wxString_in_helper(_obj1); |
218 | if (_arg1 == NULL) | |
d56cebe7 | 219 | return NULL; |
d56cebe7 RD |
220 | } |
221 | { | |
4268f798 | 222 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 223 | _result = (bool )wxXmlResource_Load(_arg0,*_arg1); |
d56cebe7 | 224 | |
4268f798 RD |
225 | wxPyEndAllowThreads(__tstate); |
226 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
227 | } _resultobj = Py_BuildValue("i",_result); |
228 | { | |
229 | if (_obj1) | |
230 | delete _arg1; | |
231 | } | |
232 | return _resultobj; | |
233 | } | |
234 | ||
235 | #define wxXmlResource_InitAllHandlers(_swigobj) (_swigobj->InitAllHandlers()) | |
236 | static PyObject *_wrap_wxXmlResource_InitAllHandlers(PyObject *self, PyObject *args, PyObject *kwargs) { | |
237 | PyObject * _resultobj; | |
238 | wxXmlResource * _arg0; | |
239 | PyObject * _argo0 = 0; | |
240 | char *_kwnames[] = { "self", NULL }; | |
241 | ||
242 | self = self; | |
243 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxXmlResource_InitAllHandlers",_kwnames,&_argo0)) | |
244 | return NULL; | |
245 | if (_argo0) { | |
246 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
247 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
248 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_InitAllHandlers. Expected _wxXmlResource_p."); | |
249 | return NULL; | |
250 | } | |
251 | } | |
252 | { | |
4268f798 | 253 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 254 | wxXmlResource_InitAllHandlers(_arg0); |
d56cebe7 | 255 | |
4268f798 RD |
256 | wxPyEndAllowThreads(__tstate); |
257 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
258 | } Py_INCREF(Py_None); |
259 | _resultobj = Py_None; | |
260 | return _resultobj; | |
261 | } | |
262 | ||
263 | #define wxXmlResource_AddHandler(_swigobj,_swigarg0) (_swigobj->AddHandler(_swigarg0)) | |
264 | static PyObject *_wrap_wxXmlResource_AddHandler(PyObject *self, PyObject *args, PyObject *kwargs) { | |
265 | PyObject * _resultobj; | |
266 | wxXmlResource * _arg0; | |
267 | wxXmlResourceHandler * _arg1; | |
268 | PyObject * _argo0 = 0; | |
269 | PyObject * _argo1 = 0; | |
270 | char *_kwnames[] = { "self","handler", NULL }; | |
271 | ||
272 | self = self; | |
273 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_AddHandler",_kwnames,&_argo0,&_argo1)) | |
274 | return NULL; | |
275 | if (_argo0) { | |
276 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
277 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
278 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_AddHandler. Expected _wxXmlResource_p."); | |
279 | return NULL; | |
280 | } | |
281 | } | |
282 | if (_argo1) { | |
283 | if (_argo1 == Py_None) { _arg1 = NULL; } | |
284 | else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxXmlResourceHandler_p")) { | |
285 | PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_AddHandler. Expected _wxXmlResourceHandler_p."); | |
286 | return NULL; | |
287 | } | |
288 | } | |
289 | { | |
4268f798 | 290 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 291 | wxXmlResource_AddHandler(_arg0,_arg1); |
d56cebe7 | 292 | |
4268f798 RD |
293 | wxPyEndAllowThreads(__tstate); |
294 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
295 | } Py_INCREF(Py_None); |
296 | _resultobj = Py_None; | |
297 | return _resultobj; | |
298 | } | |
299 | ||
300 | #define wxXmlResource_ClearHandlers(_swigobj) (_swigobj->ClearHandlers()) | |
301 | static PyObject *_wrap_wxXmlResource_ClearHandlers(PyObject *self, PyObject *args, PyObject *kwargs) { | |
302 | PyObject * _resultobj; | |
303 | wxXmlResource * _arg0; | |
304 | PyObject * _argo0 = 0; | |
305 | char *_kwnames[] = { "self", NULL }; | |
306 | ||
307 | self = self; | |
308 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxXmlResource_ClearHandlers",_kwnames,&_argo0)) | |
309 | return NULL; | |
310 | if (_argo0) { | |
311 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
312 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
313 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_ClearHandlers. Expected _wxXmlResource_p."); | |
314 | return NULL; | |
315 | } | |
316 | } | |
317 | { | |
4268f798 | 318 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 319 | wxXmlResource_ClearHandlers(_arg0); |
d56cebe7 | 320 | |
4268f798 RD |
321 | wxPyEndAllowThreads(__tstate); |
322 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
323 | } Py_INCREF(Py_None); |
324 | _resultobj = Py_None; | |
325 | return _resultobj; | |
326 | } | |
327 | ||
328 | #define wxXmlResource_LoadMenu(_swigobj,_swigarg0) (_swigobj->LoadMenu(_swigarg0)) | |
329 | static PyObject *_wrap_wxXmlResource_LoadMenu(PyObject *self, PyObject *args, PyObject *kwargs) { | |
330 | PyObject * _resultobj; | |
331 | wxMenu * _result; | |
332 | wxXmlResource * _arg0; | |
333 | wxString * _arg1; | |
334 | PyObject * _argo0 = 0; | |
335 | PyObject * _obj1 = 0; | |
336 | char *_kwnames[] = { "self","name", NULL }; | |
337 | ||
338 | self = self; | |
339 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_LoadMenu",_kwnames,&_argo0,&_obj1)) | |
340 | return NULL; | |
341 | if (_argo0) { | |
342 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
343 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
344 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadMenu. Expected _wxXmlResource_p."); | |
345 | return NULL; | |
346 | } | |
347 | } | |
348 | { | |
c8bc7bb8 RD |
349 | _arg1 = wxString_in_helper(_obj1); |
350 | if (_arg1 == NULL) | |
d56cebe7 | 351 | return NULL; |
d56cebe7 RD |
352 | } |
353 | { | |
4268f798 | 354 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 355 | _result = (wxMenu *)wxXmlResource_LoadMenu(_arg0,*_arg1); |
d56cebe7 | 356 | |
4268f798 RD |
357 | wxPyEndAllowThreads(__tstate); |
358 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
359 | }{ _resultobj = wxPyMake_wxObject(_result); } |
360 | { | |
361 | if (_obj1) | |
362 | delete _arg1; | |
363 | } | |
364 | return _resultobj; | |
365 | } | |
366 | ||
367 | #define wxXmlResource_LoadMenuBar(_swigobj,_swigarg0) (_swigobj->LoadMenuBar(_swigarg0)) | |
368 | static PyObject *_wrap_wxXmlResource_LoadMenuBar(PyObject *self, PyObject *args, PyObject *kwargs) { | |
369 | PyObject * _resultobj; | |
370 | wxMenuBar * _result; | |
371 | wxXmlResource * _arg0; | |
372 | wxString * _arg1; | |
373 | PyObject * _argo0 = 0; | |
374 | PyObject * _obj1 = 0; | |
375 | char *_kwnames[] = { "self","name", NULL }; | |
376 | ||
377 | self = self; | |
378 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_LoadMenuBar",_kwnames,&_argo0,&_obj1)) | |
379 | return NULL; | |
380 | if (_argo0) { | |
381 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
382 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
383 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadMenuBar. Expected _wxXmlResource_p."); | |
384 | return NULL; | |
385 | } | |
386 | } | |
387 | { | |
c8bc7bb8 RD |
388 | _arg1 = wxString_in_helper(_obj1); |
389 | if (_arg1 == NULL) | |
d56cebe7 | 390 | return NULL; |
d56cebe7 RD |
391 | } |
392 | { | |
4268f798 | 393 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 394 | _result = (wxMenuBar *)wxXmlResource_LoadMenuBar(_arg0,*_arg1); |
d56cebe7 | 395 | |
4268f798 RD |
396 | wxPyEndAllowThreads(__tstate); |
397 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
398 | }{ _resultobj = wxPyMake_wxObject(_result); } |
399 | { | |
400 | if (_obj1) | |
401 | delete _arg1; | |
402 | } | |
403 | return _resultobj; | |
404 | } | |
405 | ||
32a85500 RD |
406 | #define wxXmlResource_LoadMenuBarOnFrame(_swigobj,_swigarg0,_swigarg1) (_swigobj->LoadMenuBar(_swigarg0,_swigarg1)) |
407 | static PyObject *_wrap_wxXmlResource_LoadMenuBarOnFrame(PyObject *self, PyObject *args, PyObject *kwargs) { | |
408 | PyObject * _resultobj; | |
409 | wxMenuBar * _result; | |
410 | wxXmlResource * _arg0; | |
411 | wxWindow * _arg1; | |
412 | wxString * _arg2; | |
413 | PyObject * _argo0 = 0; | |
414 | PyObject * _argo1 = 0; | |
415 | PyObject * _obj2 = 0; | |
416 | char *_kwnames[] = { "self","parent","name", NULL }; | |
417 | ||
418 | self = self; | |
419 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxXmlResource_LoadMenuBarOnFrame",_kwnames,&_argo0,&_argo1,&_obj2)) | |
420 | return NULL; | |
421 | if (_argo0) { | |
422 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
423 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
424 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadMenuBarOnFrame. Expected _wxXmlResource_p."); | |
425 | return NULL; | |
426 | } | |
427 | } | |
428 | if (_argo1) { | |
429 | if (_argo1 == Py_None) { _arg1 = NULL; } | |
430 | else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxWindow_p")) { | |
431 | PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadMenuBarOnFrame. Expected _wxWindow_p."); | |
432 | return NULL; | |
433 | } | |
434 | } | |
435 | { | |
436 | _arg2 = wxString_in_helper(_obj2); | |
437 | if (_arg2 == NULL) | |
438 | return NULL; | |
439 | } | |
440 | { | |
441 | PyThreadState* __tstate = wxPyBeginAllowThreads(); | |
442 | _result = (wxMenuBar *)wxXmlResource_LoadMenuBarOnFrame(_arg0,_arg1,*_arg2); | |
443 | ||
444 | wxPyEndAllowThreads(__tstate); | |
445 | if (PyErr_Occurred()) return NULL; | |
446 | }{ _resultobj = wxPyMake_wxObject(_result); } | |
447 | { | |
448 | if (_obj2) | |
449 | delete _arg2; | |
450 | } | |
451 | return _resultobj; | |
452 | } | |
453 | ||
d56cebe7 RD |
454 | #define wxXmlResource_LoadToolBar(_swigobj,_swigarg0,_swigarg1) (_swigobj->LoadToolBar(_swigarg0,_swigarg1)) |
455 | static PyObject *_wrap_wxXmlResource_LoadToolBar(PyObject *self, PyObject *args, PyObject *kwargs) { | |
456 | PyObject * _resultobj; | |
457 | wxToolBar * _result; | |
458 | wxXmlResource * _arg0; | |
459 | wxWindow * _arg1; | |
460 | wxString * _arg2; | |
461 | PyObject * _argo0 = 0; | |
462 | PyObject * _argo1 = 0; | |
463 | PyObject * _obj2 = 0; | |
464 | char *_kwnames[] = { "self","parent","name", NULL }; | |
465 | ||
466 | self = self; | |
467 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxXmlResource_LoadToolBar",_kwnames,&_argo0,&_argo1,&_obj2)) | |
468 | return NULL; | |
469 | if (_argo0) { | |
470 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
471 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
472 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadToolBar. Expected _wxXmlResource_p."); | |
473 | return NULL; | |
474 | } | |
475 | } | |
476 | if (_argo1) { | |
477 | if (_argo1 == Py_None) { _arg1 = NULL; } | |
478 | else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxWindow_p")) { | |
479 | PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadToolBar. Expected _wxWindow_p."); | |
480 | return NULL; | |
481 | } | |
482 | } | |
483 | { | |
c8bc7bb8 RD |
484 | _arg2 = wxString_in_helper(_obj2); |
485 | if (_arg2 == NULL) | |
d56cebe7 | 486 | return NULL; |
d56cebe7 RD |
487 | } |
488 | { | |
4268f798 | 489 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 490 | _result = (wxToolBar *)wxXmlResource_LoadToolBar(_arg0,_arg1,*_arg2); |
d56cebe7 | 491 | |
4268f798 RD |
492 | wxPyEndAllowThreads(__tstate); |
493 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
494 | }{ _resultobj = wxPyMake_wxObject(_result); } |
495 | { | |
496 | if (_obj2) | |
497 | delete _arg2; | |
498 | } | |
499 | return _resultobj; | |
500 | } | |
501 | ||
502 | #define wxXmlResource_LoadDialog(_swigobj,_swigarg0,_swigarg1) (_swigobj->LoadDialog(_swigarg0,_swigarg1)) | |
503 | static PyObject *_wrap_wxXmlResource_LoadDialog(PyObject *self, PyObject *args, PyObject *kwargs) { | |
504 | PyObject * _resultobj; | |
505 | wxDialog * _result; | |
506 | wxXmlResource * _arg0; | |
507 | wxWindow * _arg1; | |
508 | wxString * _arg2; | |
509 | PyObject * _argo0 = 0; | |
510 | PyObject * _argo1 = 0; | |
511 | PyObject * _obj2 = 0; | |
512 | char *_kwnames[] = { "self","parent","name", NULL }; | |
513 | char _ptemp[128]; | |
514 | ||
515 | self = self; | |
516 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxXmlResource_LoadDialog",_kwnames,&_argo0,&_argo1,&_obj2)) | |
517 | return NULL; | |
518 | if (_argo0) { | |
519 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
520 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
521 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadDialog. Expected _wxXmlResource_p."); | |
522 | return NULL; | |
523 | } | |
524 | } | |
525 | if (_argo1) { | |
526 | if (_argo1 == Py_None) { _arg1 = NULL; } | |
527 | else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxWindow_p")) { | |
528 | PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadDialog. Expected _wxWindow_p."); | |
529 | return NULL; | |
530 | } | |
531 | } | |
532 | { | |
c8bc7bb8 RD |
533 | _arg2 = wxString_in_helper(_obj2); |
534 | if (_arg2 == NULL) | |
d56cebe7 | 535 | return NULL; |
d56cebe7 RD |
536 | } |
537 | { | |
4268f798 | 538 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 539 | _result = (wxDialog *)wxXmlResource_LoadDialog(_arg0,_arg1,*_arg2); |
d56cebe7 | 540 | |
4268f798 RD |
541 | wxPyEndAllowThreads(__tstate); |
542 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
543 | } if (_result) { |
544 | SWIG_MakePtr(_ptemp, (char *) _result,"_wxDialog_p"); | |
545 | _resultobj = Py_BuildValue("s",_ptemp); | |
546 | } else { | |
547 | Py_INCREF(Py_None); | |
548 | _resultobj = Py_None; | |
549 | } | |
550 | { | |
551 | if (_obj2) | |
552 | delete _arg2; | |
553 | } | |
554 | return _resultobj; | |
555 | } | |
556 | ||
557 | #define wxXmlResource_LoadOnDialog(_swigobj,_swigarg0,_swigarg1,_swigarg2) (_swigobj->LoadDialog(_swigarg0,_swigarg1,_swigarg2)) | |
558 | static PyObject *_wrap_wxXmlResource_LoadOnDialog(PyObject *self, PyObject *args, PyObject *kwargs) { | |
559 | PyObject * _resultobj; | |
560 | bool _result; | |
561 | wxXmlResource * _arg0; | |
562 | wxDialog * _arg1; | |
563 | wxWindow * _arg2; | |
564 | wxString * _arg3; | |
565 | PyObject * _argo0 = 0; | |
566 | PyObject * _argo1 = 0; | |
567 | PyObject * _argo2 = 0; | |
568 | PyObject * _obj3 = 0; | |
569 | char *_kwnames[] = { "self","dlg","parent","name", NULL }; | |
570 | ||
571 | self = self; | |
572 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOOO:wxXmlResource_LoadOnDialog",_kwnames,&_argo0,&_argo1,&_argo2,&_obj3)) | |
573 | return NULL; | |
574 | if (_argo0) { | |
575 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
576 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
577 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadOnDialog. Expected _wxXmlResource_p."); | |
578 | return NULL; | |
579 | } | |
580 | } | |
581 | if (_argo1) { | |
582 | if (_argo1 == Py_None) { _arg1 = NULL; } | |
583 | else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxDialog_p")) { | |
584 | PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadOnDialog. Expected _wxDialog_p."); | |
585 | return NULL; | |
586 | } | |
587 | } | |
588 | if (_argo2) { | |
589 | if (_argo2 == Py_None) { _arg2 = NULL; } | |
590 | else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxWindow_p")) { | |
591 | PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxXmlResource_LoadOnDialog. Expected _wxWindow_p."); | |
592 | return NULL; | |
593 | } | |
594 | } | |
595 | { | |
c8bc7bb8 RD |
596 | _arg3 = wxString_in_helper(_obj3); |
597 | if (_arg3 == NULL) | |
d56cebe7 | 598 | return NULL; |
d56cebe7 RD |
599 | } |
600 | { | |
4268f798 | 601 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 602 | _result = (bool )wxXmlResource_LoadOnDialog(_arg0,_arg1,_arg2,*_arg3); |
d56cebe7 | 603 | |
4268f798 RD |
604 | wxPyEndAllowThreads(__tstate); |
605 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
606 | } _resultobj = Py_BuildValue("i",_result); |
607 | { | |
608 | if (_obj3) | |
609 | delete _arg3; | |
610 | } | |
611 | return _resultobj; | |
612 | } | |
613 | ||
614 | #define wxXmlResource_LoadPanel(_swigobj,_swigarg0,_swigarg1) (_swigobj->LoadPanel(_swigarg0,_swigarg1)) | |
615 | static PyObject *_wrap_wxXmlResource_LoadPanel(PyObject *self, PyObject *args, PyObject *kwargs) { | |
616 | PyObject * _resultobj; | |
617 | wxPanel * _result; | |
618 | wxXmlResource * _arg0; | |
619 | wxWindow * _arg1; | |
620 | wxString * _arg2; | |
621 | PyObject * _argo0 = 0; | |
622 | PyObject * _argo1 = 0; | |
623 | PyObject * _obj2 = 0; | |
624 | char *_kwnames[] = { "self","parent","name", NULL }; | |
625 | char _ptemp[128]; | |
626 | ||
627 | self = self; | |
628 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxXmlResource_LoadPanel",_kwnames,&_argo0,&_argo1,&_obj2)) | |
629 | return NULL; | |
630 | if (_argo0) { | |
631 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
632 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
633 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadPanel. Expected _wxXmlResource_p."); | |
634 | return NULL; | |
635 | } | |
636 | } | |
637 | if (_argo1) { | |
638 | if (_argo1 == Py_None) { _arg1 = NULL; } | |
639 | else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxWindow_p")) { | |
640 | PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadPanel. Expected _wxWindow_p."); | |
641 | return NULL; | |
642 | } | |
643 | } | |
644 | { | |
c8bc7bb8 RD |
645 | _arg2 = wxString_in_helper(_obj2); |
646 | if (_arg2 == NULL) | |
d56cebe7 | 647 | return NULL; |
d56cebe7 RD |
648 | } |
649 | { | |
4268f798 | 650 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 651 | _result = (wxPanel *)wxXmlResource_LoadPanel(_arg0,_arg1,*_arg2); |
d56cebe7 | 652 | |
4268f798 RD |
653 | wxPyEndAllowThreads(__tstate); |
654 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
655 | } if (_result) { |
656 | SWIG_MakePtr(_ptemp, (char *) _result,"_wxPanel_p"); | |
657 | _resultobj = Py_BuildValue("s",_ptemp); | |
658 | } else { | |
659 | Py_INCREF(Py_None); | |
660 | _resultobj = Py_None; | |
661 | } | |
662 | { | |
663 | if (_obj2) | |
664 | delete _arg2; | |
665 | } | |
666 | return _resultobj; | |
667 | } | |
668 | ||
669 | #define wxXmlResource_LoadOnPanel(_swigobj,_swigarg0,_swigarg1,_swigarg2) (_swigobj->LoadPanel(_swigarg0,_swigarg1,_swigarg2)) | |
670 | static PyObject *_wrap_wxXmlResource_LoadOnPanel(PyObject *self, PyObject *args, PyObject *kwargs) { | |
671 | PyObject * _resultobj; | |
672 | bool _result; | |
673 | wxXmlResource * _arg0; | |
674 | wxPanel * _arg1; | |
675 | wxWindow * _arg2; | |
676 | wxString * _arg3; | |
677 | PyObject * _argo0 = 0; | |
678 | PyObject * _argo1 = 0; | |
679 | PyObject * _argo2 = 0; | |
680 | PyObject * _obj3 = 0; | |
681 | char *_kwnames[] = { "self","panel","parent","name", NULL }; | |
682 | ||
683 | self = self; | |
684 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOOO:wxXmlResource_LoadOnPanel",_kwnames,&_argo0,&_argo1,&_argo2,&_obj3)) | |
685 | return NULL; | |
686 | if (_argo0) { | |
687 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
688 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
689 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadOnPanel. Expected _wxXmlResource_p."); | |
690 | return NULL; | |
691 | } | |
692 | } | |
693 | if (_argo1) { | |
694 | if (_argo1 == Py_None) { _arg1 = NULL; } | |
695 | else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxPanel_p")) { | |
696 | PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadOnPanel. Expected _wxPanel_p."); | |
697 | return NULL; | |
698 | } | |
699 | } | |
700 | if (_argo2) { | |
701 | if (_argo2 == Py_None) { _arg2 = NULL; } | |
702 | else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxWindow_p")) { | |
703 | PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxXmlResource_LoadOnPanel. Expected _wxWindow_p."); | |
704 | return NULL; | |
705 | } | |
706 | } | |
707 | { | |
c8bc7bb8 RD |
708 | _arg3 = wxString_in_helper(_obj3); |
709 | if (_arg3 == NULL) | |
d56cebe7 | 710 | return NULL; |
d56cebe7 RD |
711 | } |
712 | { | |
4268f798 | 713 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 714 | _result = (bool )wxXmlResource_LoadOnPanel(_arg0,_arg1,_arg2,*_arg3); |
d56cebe7 | 715 | |
4268f798 RD |
716 | wxPyEndAllowThreads(__tstate); |
717 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
718 | } _resultobj = Py_BuildValue("i",_result); |
719 | { | |
720 | if (_obj3) | |
721 | delete _arg3; | |
722 | } | |
723 | return _resultobj; | |
724 | } | |
725 | ||
726 | #define wxXmlResource_LoadFrame(_swigobj,_swigarg0,_swigarg1,_swigarg2) (_swigobj->LoadFrame(_swigarg0,_swigarg1,_swigarg2)) | |
727 | static PyObject *_wrap_wxXmlResource_LoadFrame(PyObject *self, PyObject *args, PyObject *kwargs) { | |
728 | PyObject * _resultobj; | |
729 | bool _result; | |
730 | wxXmlResource * _arg0; | |
731 | wxFrame * _arg1; | |
732 | wxWindow * _arg2; | |
733 | wxString * _arg3; | |
734 | PyObject * _argo0 = 0; | |
735 | PyObject * _argo1 = 0; | |
736 | PyObject * _argo2 = 0; | |
737 | PyObject * _obj3 = 0; | |
738 | char *_kwnames[] = { "self","frame","parent","name", NULL }; | |
739 | ||
740 | self = self; | |
741 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOOO:wxXmlResource_LoadFrame",_kwnames,&_argo0,&_argo1,&_argo2,&_obj3)) | |
742 | return NULL; | |
743 | if (_argo0) { | |
744 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
745 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
746 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadFrame. Expected _wxXmlResource_p."); | |
747 | return NULL; | |
748 | } | |
749 | } | |
750 | if (_argo1) { | |
751 | if (_argo1 == Py_None) { _arg1 = NULL; } | |
752 | else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxFrame_p")) { | |
753 | PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadFrame. Expected _wxFrame_p."); | |
754 | return NULL; | |
755 | } | |
756 | } | |
757 | if (_argo2) { | |
758 | if (_argo2 == Py_None) { _arg2 = NULL; } | |
759 | else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxWindow_p")) { | |
760 | PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxXmlResource_LoadFrame. Expected _wxWindow_p."); | |
761 | return NULL; | |
762 | } | |
763 | } | |
764 | { | |
c8bc7bb8 RD |
765 | _arg3 = wxString_in_helper(_obj3); |
766 | if (_arg3 == NULL) | |
d56cebe7 | 767 | return NULL; |
d56cebe7 RD |
768 | } |
769 | { | |
4268f798 | 770 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 771 | _result = (bool )wxXmlResource_LoadFrame(_arg0,_arg1,_arg2,*_arg3); |
d56cebe7 | 772 | |
4268f798 RD |
773 | wxPyEndAllowThreads(__tstate); |
774 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
775 | } _resultobj = Py_BuildValue("i",_result); |
776 | { | |
777 | if (_obj3) | |
778 | delete _arg3; | |
779 | } | |
780 | return _resultobj; | |
781 | } | |
782 | ||
783 | #define wxXmlResource_LoadBitmap(_swigobj,_swigarg0) (_swigobj->LoadBitmap(_swigarg0)) | |
784 | static PyObject *_wrap_wxXmlResource_LoadBitmap(PyObject *self, PyObject *args, PyObject *kwargs) { | |
785 | PyObject * _resultobj; | |
786 | wxBitmap * _result; | |
787 | wxXmlResource * _arg0; | |
788 | wxString * _arg1; | |
789 | PyObject * _argo0 = 0; | |
790 | PyObject * _obj1 = 0; | |
791 | char *_kwnames[] = { "self","name", NULL }; | |
792 | char _ptemp[128]; | |
793 | ||
794 | self = self; | |
795 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_LoadBitmap",_kwnames,&_argo0,&_obj1)) | |
796 | return NULL; | |
797 | if (_argo0) { | |
798 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
799 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
800 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadBitmap. Expected _wxXmlResource_p."); | |
801 | return NULL; | |
802 | } | |
803 | } | |
804 | { | |
c8bc7bb8 RD |
805 | _arg1 = wxString_in_helper(_obj1); |
806 | if (_arg1 == NULL) | |
d56cebe7 | 807 | return NULL; |
d56cebe7 RD |
808 | } |
809 | { | |
4268f798 | 810 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 811 | _result = new wxBitmap (wxXmlResource_LoadBitmap(_arg0,*_arg1)); |
d56cebe7 | 812 | |
4268f798 RD |
813 | wxPyEndAllowThreads(__tstate); |
814 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
815 | } SWIG_MakePtr(_ptemp, (void *) _result,"_wxBitmap_p"); |
816 | _resultobj = Py_BuildValue("s",_ptemp); | |
817 | { | |
818 | if (_obj1) | |
819 | delete _arg1; | |
820 | } | |
821 | return _resultobj; | |
822 | } | |
823 | ||
824 | #define wxXmlResource_LoadIcon(_swigobj,_swigarg0) (_swigobj->LoadIcon(_swigarg0)) | |
825 | static PyObject *_wrap_wxXmlResource_LoadIcon(PyObject *self, PyObject *args, PyObject *kwargs) { | |
826 | PyObject * _resultobj; | |
827 | wxIcon * _result; | |
828 | wxXmlResource * _arg0; | |
829 | wxString * _arg1; | |
830 | PyObject * _argo0 = 0; | |
831 | PyObject * _obj1 = 0; | |
832 | char *_kwnames[] = { "self","name", NULL }; | |
833 | char _ptemp[128]; | |
834 | ||
835 | self = self; | |
836 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_LoadIcon",_kwnames,&_argo0,&_obj1)) | |
837 | return NULL; | |
838 | if (_argo0) { | |
839 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
840 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
841 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadIcon. Expected _wxXmlResource_p."); | |
842 | return NULL; | |
843 | } | |
844 | } | |
845 | { | |
c8bc7bb8 RD |
846 | _arg1 = wxString_in_helper(_obj1); |
847 | if (_arg1 == NULL) | |
d56cebe7 | 848 | return NULL; |
d56cebe7 RD |
849 | } |
850 | { | |
4268f798 | 851 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 852 | _result = new wxIcon (wxXmlResource_LoadIcon(_arg0,*_arg1)); |
d56cebe7 | 853 | |
4268f798 RD |
854 | wxPyEndAllowThreads(__tstate); |
855 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
856 | } SWIG_MakePtr(_ptemp, (void *) _result,"_wxIcon_p"); |
857 | _resultobj = Py_BuildValue("s",_ptemp); | |
858 | { | |
859 | if (_obj1) | |
860 | delete _arg1; | |
861 | } | |
862 | return _resultobj; | |
863 | } | |
864 | ||
865 | #define wxXmlResource_AttachUnknownControl(_swigobj,_swigarg0,_swigarg1,_swigarg2) (_swigobj->AttachUnknownControl(_swigarg0,_swigarg1,_swigarg2)) | |
866 | static PyObject *_wrap_wxXmlResource_AttachUnknownControl(PyObject *self, PyObject *args, PyObject *kwargs) { | |
867 | PyObject * _resultobj; | |
868 | bool _result; | |
869 | wxXmlResource * _arg0; | |
870 | wxString * _arg1; | |
871 | wxWindow * _arg2; | |
872 | wxWindow * _arg3 = (wxWindow *) NULL; | |
873 | PyObject * _argo0 = 0; | |
874 | PyObject * _obj1 = 0; | |
875 | PyObject * _argo2 = 0; | |
876 | PyObject * _argo3 = 0; | |
877 | char *_kwnames[] = { "self","name","control","parent", NULL }; | |
878 | ||
879 | self = self; | |
880 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO|O:wxXmlResource_AttachUnknownControl",_kwnames,&_argo0,&_obj1,&_argo2,&_argo3)) | |
881 | return NULL; | |
882 | if (_argo0) { | |
883 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
884 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
885 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_AttachUnknownControl. Expected _wxXmlResource_p."); | |
886 | return NULL; | |
887 | } | |
888 | } | |
889 | { | |
c8bc7bb8 RD |
890 | _arg1 = wxString_in_helper(_obj1); |
891 | if (_arg1 == NULL) | |
d56cebe7 | 892 | return NULL; |
d56cebe7 RD |
893 | } |
894 | if (_argo2) { | |
895 | if (_argo2 == Py_None) { _arg2 = NULL; } | |
896 | else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxWindow_p")) { | |
897 | PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxXmlResource_AttachUnknownControl. Expected _wxWindow_p."); | |
898 | return NULL; | |
899 | } | |
900 | } | |
901 | if (_argo3) { | |
902 | if (_argo3 == Py_None) { _arg3 = NULL; } | |
903 | else if (SWIG_GetPtrObj(_argo3,(void **) &_arg3,"_wxWindow_p")) { | |
904 | PyErr_SetString(PyExc_TypeError,"Type error in argument 4 of wxXmlResource_AttachUnknownControl. Expected _wxWindow_p."); | |
905 | return NULL; | |
906 | } | |
907 | } | |
908 | { | |
4268f798 | 909 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 910 | _result = (bool )wxXmlResource_AttachUnknownControl(_arg0,*_arg1,_arg2,_arg3); |
d56cebe7 | 911 | |
4268f798 RD |
912 | wxPyEndAllowThreads(__tstate); |
913 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
914 | } _resultobj = Py_BuildValue("i",_result); |
915 | { | |
916 | if (_obj1) | |
917 | delete _arg1; | |
918 | } | |
919 | return _resultobj; | |
920 | } | |
921 | ||
c6c593e8 | 922 | static PyObject *_wrap_wxXmlResource_GetXRCID(PyObject *self, PyObject *args, PyObject *kwargs) { |
d56cebe7 RD |
923 | PyObject * _resultobj; |
924 | int _result; | |
1496068d RD |
925 | wxString * _arg0; |
926 | PyObject * _obj0 = 0; | |
d56cebe7 RD |
927 | char *_kwnames[] = { "str_id", NULL }; |
928 | ||
929 | self = self; | |
1496068d | 930 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxXmlResource_GetXRCID",_kwnames,&_obj0)) |
d56cebe7 | 931 | return NULL; |
1496068d RD |
932 | { |
933 | _arg0 = wxString_in_helper(_obj0); | |
934 | if (_arg0 == NULL) | |
935 | return NULL; | |
936 | } | |
d56cebe7 | 937 | { |
4268f798 | 938 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
1496068d | 939 | _result = (int )wxXmlResource::GetXRCID(*_arg0); |
d56cebe7 | 940 | |
4268f798 RD |
941 | wxPyEndAllowThreads(__tstate); |
942 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 | 943 | } _resultobj = Py_BuildValue("i",_result); |
1496068d RD |
944 | { |
945 | if (_obj0) | |
946 | delete _arg0; | |
947 | } | |
d56cebe7 RD |
948 | return _resultobj; |
949 | } | |
950 | ||
951 | #define wxXmlResource_GetVersion(_swigobj) (_swigobj->GetVersion()) | |
952 | static PyObject *_wrap_wxXmlResource_GetVersion(PyObject *self, PyObject *args, PyObject *kwargs) { | |
953 | PyObject * _resultobj; | |
954 | long _result; | |
955 | wxXmlResource * _arg0; | |
956 | PyObject * _argo0 = 0; | |
957 | char *_kwnames[] = { "self", NULL }; | |
958 | ||
959 | self = self; | |
960 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxXmlResource_GetVersion",_kwnames,&_argo0)) | |
961 | return NULL; | |
962 | if (_argo0) { | |
963 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
964 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
965 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_GetVersion. Expected _wxXmlResource_p."); | |
966 | return NULL; | |
967 | } | |
968 | } | |
969 | { | |
4268f798 | 970 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 971 | _result = (long )wxXmlResource_GetVersion(_arg0); |
d56cebe7 | 972 | |
4268f798 RD |
973 | wxPyEndAllowThreads(__tstate); |
974 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
975 | } _resultobj = Py_BuildValue("l",_result); |
976 | return _resultobj; | |
977 | } | |
978 | ||
979 | #define wxXmlResource_CompareVersion(_swigobj,_swigarg0,_swigarg1,_swigarg2,_swigarg3) (_swigobj->CompareVersion(_swigarg0,_swigarg1,_swigarg2,_swigarg3)) | |
980 | static PyObject *_wrap_wxXmlResource_CompareVersion(PyObject *self, PyObject *args, PyObject *kwargs) { | |
981 | PyObject * _resultobj; | |
982 | int _result; | |
983 | wxXmlResource * _arg0; | |
984 | int _arg1; | |
985 | int _arg2; | |
986 | int _arg3; | |
987 | int _arg4; | |
988 | PyObject * _argo0 = 0; | |
989 | char *_kwnames[] = { "self","major","minor","release","revision", NULL }; | |
990 | ||
991 | self = self; | |
992 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiiii:wxXmlResource_CompareVersion",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3,&_arg4)) | |
993 | return NULL; | |
994 | if (_argo0) { | |
995 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
996 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
997 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_CompareVersion. Expected _wxXmlResource_p."); | |
998 | return NULL; | |
999 | } | |
1000 | } | |
1001 | { | |
4268f798 | 1002 | PyThreadState* __tstate = wxPyBeginAllowThreads(); |
c8bc7bb8 | 1003 | _result = (int )wxXmlResource_CompareVersion(_arg0,_arg1,_arg2,_arg3,_arg4); |
d56cebe7 | 1004 | |
4268f798 RD |
1005 | wxPyEndAllowThreads(__tstate); |
1006 | if (PyErr_Occurred()) return NULL; | |
d56cebe7 RD |
1007 | } _resultobj = Py_BuildValue("i",_result); |
1008 | return _resultobj; | |
1009 | } | |
1010 | ||
ce914f73 RD |
1011 | static PyObject *_wrap_wxXmlResource_Get(PyObject *self, PyObject *args, PyObject *kwargs) { |
1012 | PyObject * _resultobj; | |
1013 | wxXmlResource * _result; | |
1014 | char *_kwnames[] = { NULL }; | |
1015 | char _ptemp[128]; | |
1016 | ||
1017 | self = self; | |
1018 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,":wxXmlResource_Get",_kwnames)) | |
1019 | return NULL; | |
1020 | { | |
1021 | PyThreadState* __tstate = wxPyBeginAllowThreads(); | |
c8bc7bb8 | 1022 | _result = (wxXmlResource *)wxXmlResource::Get(); |
ce914f73 RD |
1023 | |
1024 | wxPyEndAllowThreads(__tstate); | |
1025 | if (PyErr_Occurred()) return NULL; | |
1026 | } if (_result) { | |
1027 | SWIG_MakePtr(_ptemp, (char *) _result,"_wxXmlResource_p"); | |
1028 | _resultobj = Py_BuildValue("s",_ptemp); | |
1029 | } else { | |
1030 | Py_INCREF(Py_None); | |
1031 | _resultobj = Py_None; | |
1032 | } | |
1033 | return _resultobj; | |
1034 | } | |
1035 | ||
1036 | static PyObject *_wrap_wxXmlResource_Set(PyObject *self, PyObject *args, PyObject *kwargs) { | |
1037 | PyObject * _resultobj; | |
1038 | wxXmlResource * _result; | |
1039 | wxXmlResource * _arg0; | |
1040 | PyObject * _argo0 = 0; | |
1041 | char *_kwnames[] = { "res", NULL }; | |
1042 | char _ptemp[128]; | |
1043 | ||
1044 | self = self; | |
1045 | if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxXmlResource_Set",_kwnames,&_argo0)) | |
1046 | return NULL; | |
1047 | if (_argo0) { | |
1048 | if (_argo0 == Py_None) { _arg0 = NULL; } | |
1049 | else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) { | |
1050 | PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_Set. Expected _wxXmlResource_p."); | |
1051 | return NULL; | |
1052 | } | |
1053 | } | |
1054 | { | |
1055 | PyThreadState* __tstate = wxPyBeginAllowThreads(); | |
c8bc7bb8 | 1056 | _result = (wxXmlResource *)wxXmlResource::Set(_arg0); |
ce914f73 RD |
1057 | |
1058 | wxPyEndAllowThreads(__tstate); | |
1059 | if (PyErr_Occurred()) return NULL; | |
1060 | } if (_result) { | |
1061 | SWIG_MakePtr(_ptemp, (char *) _result,"_wxXmlResource_p"); | |
1062 | _resultobj = Py_BuildValue("s",_ptemp); | |
1063 | } else { | |
1064 | Py_INCREF(Py_None); | |
1065 | _resultobj = Py_None; | |
1066 | } | |
1067 | return _resultobj; | |
1068 | } | |
1069 | ||
d56cebe7 | 1070 | static PyMethodDef xrccMethods[] = { |
ce914f73 RD |
1071 | { "wxXmlResource_Set", (PyCFunction) _wrap_wxXmlResource_Set, METH_VARARGS | METH_KEYWORDS }, |
1072 | { "wxXmlResource_Get", (PyCFunction) _wrap_wxXmlResource_Get, METH_VARARGS | METH_KEYWORDS }, | |
d56cebe7 RD |
1073 | { "wxXmlResource_CompareVersion", (PyCFunction) _wrap_wxXmlResource_CompareVersion, METH_VARARGS | METH_KEYWORDS }, |
1074 | { "wxXmlResource_GetVersion", (PyCFunction) _wrap_wxXmlResource_GetVersion, METH_VARARGS | METH_KEYWORDS }, | |
c6c593e8 | 1075 | { "wxXmlResource_GetXRCID", (PyCFunction) _wrap_wxXmlResource_GetXRCID, METH_VARARGS | METH_KEYWORDS }, |
d56cebe7 RD |
1076 | { "wxXmlResource_AttachUnknownControl", (PyCFunction) _wrap_wxXmlResource_AttachUnknownControl, METH_VARARGS | METH_KEYWORDS }, |
1077 | { "wxXmlResource_LoadIcon", (PyCFunction) _wrap_wxXmlResource_LoadIcon, METH_VARARGS | METH_KEYWORDS }, | |
1078 | { "wxXmlResource_LoadBitmap", (PyCFunction) _wrap_wxXmlResource_LoadBitmap, METH_VARARGS | METH_KEYWORDS }, | |
1079 | { "wxXmlResource_LoadFrame", (PyCFunction) _wrap_wxXmlResource_LoadFrame, METH_VARARGS | METH_KEYWORDS }, | |
1080 | { "wxXmlResource_LoadOnPanel", (PyCFunction) _wrap_wxXmlResource_LoadOnPanel, METH_VARARGS | METH_KEYWORDS }, | |
1081 | { "wxXmlResource_LoadPanel", (PyCFunction) _wrap_wxXmlResource_LoadPanel, METH_VARARGS | METH_KEYWORDS }, | |
1082 | { "wxXmlResource_LoadOnDialog", (PyCFunction) _wrap_wxXmlResource_LoadOnDialog, METH_VARARGS | METH_KEYWORDS }, | |
1083 | { "wxXmlResource_LoadDialog", (PyCFunction) _wrap_wxXmlResource_LoadDialog, METH_VARARGS | METH_KEYWORDS }, | |
1084 | { "wxXmlResource_LoadToolBar", (PyCFunction) _wrap_wxXmlResource_LoadToolBar, METH_VARARGS | METH_KEYWORDS }, | |
32a85500 | 1085 | { "wxXmlResource_LoadMenuBarOnFrame", (PyCFunction) _wrap_wxXmlResource_LoadMenuBarOnFrame, METH_VARARGS | METH_KEYWORDS }, |
d56cebe7 RD |
1086 | { "wxXmlResource_LoadMenuBar", (PyCFunction) _wrap_wxXmlResource_LoadMenuBar, METH_VARARGS | METH_KEYWORDS }, |
1087 | { "wxXmlResource_LoadMenu", (PyCFunction) _wrap_wxXmlResource_LoadMenu, METH_VARARGS | METH_KEYWORDS }, | |
1088 | { "wxXmlResource_ClearHandlers", (PyCFunction) _wrap_wxXmlResource_ClearHandlers, METH_VARARGS | METH_KEYWORDS }, | |
1089 | { "wxXmlResource_AddHandler", (PyCFunction) _wrap_wxXmlResource_AddHandler, METH_VARARGS | METH_KEYWORDS }, | |
1090 | { "wxXmlResource_InitAllHandlers", (PyCFunction) _wrap_wxXmlResource_InitAllHandlers, METH_VARARGS | METH_KEYWORDS }, | |
1091 | { "wxXmlResource_Load", (PyCFunction) _wrap_wxXmlResource_Load, METH_VARARGS | METH_KEYWORDS }, | |
1092 | { "delete_wxXmlResource", (PyCFunction) _wrap_delete_wxXmlResource, METH_VARARGS | METH_KEYWORDS }, | |
1093 | { "new_wxXmlResource", (PyCFunction) _wrap_new_wxXmlResource, METH_VARARGS | METH_KEYWORDS }, | |
1094 | { "new_wxXmlResourceEmpty", (PyCFunction) _wrap_new_wxXmlResourceEmpty, METH_VARARGS | METH_KEYWORDS }, | |
1095 | { NULL, NULL } | |
1096 | }; | |
1097 | #ifdef __cplusplus | |
1098 | } | |
1099 | #endif | |
1100 | /* | |
1101 | * This table is used by the pointer type-checker | |
1102 | */ | |
1103 | static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = { | |
1104 | { "_signed_long","_long",0}, | |
1105 | { "_wxPrintQuality","_wxCoord",0}, | |
1106 | { "_wxPrintQuality","_int",0}, | |
1107 | { "_wxPrintQuality","_signed_int",0}, | |
1108 | { "_wxPrintQuality","_unsigned_int",0}, | |
1109 | { "_wxPrintQuality","_wxWindowID",0}, | |
1110 | { "_wxPrintQuality","_uint",0}, | |
1111 | { "_wxPrintQuality","_EBool",0}, | |
1112 | { "_wxPrintQuality","_size_t",0}, | |
1113 | { "_wxPrintQuality","_time_t",0}, | |
1114 | { "_byte","_unsigned_char",0}, | |
1115 | { "_long","_unsigned_long",0}, | |
1116 | { "_long","_signed_long",0}, | |
1117 | { "_size_t","_wxCoord",0}, | |
1118 | { "_size_t","_wxPrintQuality",0}, | |
1119 | { "_size_t","_time_t",0}, | |
1120 | { "_size_t","_unsigned_int",0}, | |
1121 | { "_size_t","_int",0}, | |
1122 | { "_size_t","_wxWindowID",0}, | |
1123 | { "_size_t","_uint",0}, | |
1124 | { "_uint","_wxCoord",0}, | |
1125 | { "_uint","_wxPrintQuality",0}, | |
1126 | { "_uint","_time_t",0}, | |
1127 | { "_uint","_size_t",0}, | |
1128 | { "_uint","_unsigned_int",0}, | |
1129 | { "_uint","_int",0}, | |
1130 | { "_uint","_wxWindowID",0}, | |
1131 | { "_wxChar","_char",0}, | |
1132 | { "_char","_wxChar",0}, | |
65fe3842 | 1133 | { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0}, |
d56cebe7 RD |
1134 | { "_EBool","_wxCoord",0}, |
1135 | { "_EBool","_wxPrintQuality",0}, | |
1136 | { "_EBool","_signed_int",0}, | |
1137 | { "_EBool","_int",0}, | |
1138 | { "_EBool","_wxWindowID",0}, | |
1139 | { "_unsigned_long","_long",0}, | |
65fe3842 | 1140 | { "_wxNativeFontInfo","_struct_wxNativeFontInfo",0}, |
d56cebe7 RD |
1141 | { "_signed_int","_wxCoord",0}, |
1142 | { "_signed_int","_wxPrintQuality",0}, | |
1143 | { "_signed_int","_EBool",0}, | |
1144 | { "_signed_int","_wxWindowID",0}, | |
1145 | { "_signed_int","_int",0}, | |
1146 | { "_WXTYPE","_wxDateTime_t",0}, | |
1147 | { "_WXTYPE","_short",0}, | |
1148 | { "_WXTYPE","_signed_short",0}, | |
1149 | { "_WXTYPE","_unsigned_short",0}, | |
1150 | { "_unsigned_short","_wxDateTime_t",0}, | |
1151 | { "_unsigned_short","_WXTYPE",0}, | |
1152 | { "_unsigned_short","_short",0}, | |
1153 | { "_wxObject","_wxXmlResource",SwigwxXmlResourceTowxObject}, | |
1154 | { "_signed_short","_WXTYPE",0}, | |
1155 | { "_signed_short","_short",0}, | |
1156 | { "_unsigned_char","_byte",0}, | |
1157 | { "_unsigned_int","_wxCoord",0}, | |
1158 | { "_unsigned_int","_wxPrintQuality",0}, | |
1159 | { "_unsigned_int","_time_t",0}, | |
1160 | { "_unsigned_int","_size_t",0}, | |
1161 | { "_unsigned_int","_uint",0}, | |
1162 | { "_unsigned_int","_wxWindowID",0}, | |
1163 | { "_unsigned_int","_int",0}, | |
1164 | { "_short","_wxDateTime_t",0}, | |
1165 | { "_short","_WXTYPE",0}, | |
1166 | { "_short","_unsigned_short",0}, | |
1167 | { "_short","_signed_short",0}, | |
1168 | { "_wxWindowID","_wxCoord",0}, | |
1169 | { "_wxWindowID","_wxPrintQuality",0}, | |
1170 | { "_wxWindowID","_time_t",0}, | |
1171 | { "_wxWindowID","_size_t",0}, | |
1172 | { "_wxWindowID","_EBool",0}, | |
1173 | { "_wxWindowID","_uint",0}, | |
1174 | { "_wxWindowID","_int",0}, | |
1175 | { "_wxWindowID","_signed_int",0}, | |
1176 | { "_wxWindowID","_unsigned_int",0}, | |
1177 | { "_int","_wxCoord",0}, | |
1178 | { "_int","_wxPrintQuality",0}, | |
1179 | { "_int","_time_t",0}, | |
1180 | { "_int","_size_t",0}, | |
1181 | { "_int","_EBool",0}, | |
1182 | { "_int","_uint",0}, | |
1183 | { "_int","_wxWindowID",0}, | |
1184 | { "_int","_unsigned_int",0}, | |
1185 | { "_int","_signed_int",0}, | |
1186 | { "_wxDateTime_t","_unsigned_short",0}, | |
1187 | { "_wxDateTime_t","_short",0}, | |
1188 | { "_wxDateTime_t","_WXTYPE",0}, | |
1189 | { "_time_t","_wxCoord",0}, | |
1190 | { "_time_t","_wxPrintQuality",0}, | |
1191 | { "_time_t","_unsigned_int",0}, | |
1192 | { "_time_t","_int",0}, | |
1193 | { "_time_t","_wxWindowID",0}, | |
1194 | { "_time_t","_uint",0}, | |
1195 | { "_time_t","_size_t",0}, | |
1196 | { "_wxCoord","_int",0}, | |
1197 | { "_wxCoord","_signed_int",0}, | |
1198 | { "_wxCoord","_unsigned_int",0}, | |
1199 | { "_wxCoord","_wxWindowID",0}, | |
1200 | { "_wxCoord","_uint",0}, | |
1201 | { "_wxCoord","_EBool",0}, | |
1202 | { "_wxCoord","_size_t",0}, | |
1203 | { "_wxCoord","_time_t",0}, | |
1204 | { "_wxCoord","_wxPrintQuality",0}, | |
1205 | {0,0,0}}; | |
1206 | ||
1207 | static PyObject *SWIG_globals; | |
1208 | #ifdef __cplusplus | |
1209 | extern "C" | |
1210 | #endif | |
1211 | SWIGEXPORT(void) initxrcc() { | |
1212 | PyObject *m, *d; | |
1213 | SWIG_globals = SWIG_newvarlink(); | |
1214 | m = Py_InitModule("xrcc", xrccMethods); | |
1215 | d = PyModule_GetDict(m); | |
b5a5d647 RD |
1216 | PyDict_SetItemString(d,"wxXRC_USE_LOCALE", PyInt_FromLong((long) wxXRC_USE_LOCALE)); |
1217 | PyDict_SetItemString(d,"wxXRC_NO_SUBCLASSING", PyInt_FromLong((long) wxXRC_NO_SUBCLASSING)); | |
d56cebe7 RD |
1218 | |
1219 | ||
1220 | wxClassInfo::CleanUpClasses(); | |
1221 | wxClassInfo::InitializeClasses(); | |
1222 | ||
d56cebe7 | 1223 | wxXmlInitResourceModule(); |
ce914f73 | 1224 | wxXmlResource::Get()->InitAllHandlers(); |
d56cebe7 RD |
1225 | |
1226 | { | |
1227 | int i; | |
1228 | for (i = 0; _swig_mapping[i].n1; i++) | |
1229 | SWIG_RegisterMapping(_swig_mapping[i].n1,_swig_mapping[i].n2,_swig_mapping[i].pcnv); | |
1230 | } | |
1231 | } |